summaryrefslogtreecommitdiff
path: root/packages/integrations/vue/test/basics.test.js
diff options
context:
space:
mode:
authorGravatar Matthew Phillips <matthew@skypack.dev> 2023-10-27 08:11:46 -0400
committerGravatar GitHub <noreply@github.com> 2023-10-27 08:11:46 -0400
commitc77f55d9c075569be018dc1fb5a42c932b9071c7 (patch)
tree05ef0749d600bd73071cb5e509b2b1212bb3d6ab /packages/integrations/vue/test/basics.test.js
parentca90b47cfc5e00f5065cf461e2fe50db62215e49 (diff)
downloadastro-c77f55d9c075569be018dc1fb5a42c932b9071c7.tar.gz
astro-c77f55d9c075569be018dc1fb5a42c932b9071c7.tar.zst
astro-c77f55d9c075569be018dc1fb5a42c932b9071c7.zip
Prevent passing slot names as props (#8930)
Co-authored-by: Sarah Rainsberger <5098874+sarah11918@users.noreply.github.com> Co-authored-by: Nate Moore <7118177+natemoo-re@users.noreply.github.com>
Diffstat (limited to 'packages/integrations/vue/test/basics.test.js')
-rw-r--r--packages/integrations/vue/test/basics.test.js24
1 files changed, 24 insertions, 0 deletions
diff --git a/packages/integrations/vue/test/basics.test.js b/packages/integrations/vue/test/basics.test.js
new file mode 100644
index 000000000..a4bdc7f87
--- /dev/null
+++ b/packages/integrations/vue/test/basics.test.js
@@ -0,0 +1,24 @@
+import { loadFixture } from './test-utils.js';
+import { expect } from 'chai';
+import { parseHTML } from 'linkedom';
+describe('Basics', () => {
+ /** @type {import('./test-utils').Fixture} */
+ let fixture;
+
+ before(async () => {
+ fixture = await loadFixture({
+ root: './fixtures/basics/',
+ });
+ await fixture.build();
+ });
+
+ it('Slots are added without the slot attribute', async () => {
+ const data = await fixture.readFile('/index.html');
+ const { document } = parseHTML(data);
+ const bar = document.querySelector('#foo');
+
+ expect(bar).not.to.be.undefined;
+ expect(bar.getAttribute('slot')).to.be.null;
+ });
+
+});