Skip to content

Commit

Permalink
Remove linkedom reference
Browse files Browse the repository at this point in the history
  • Loading branch information
Fryuni committed Oct 5, 2024
1 parent e17dc00 commit 39fca61
Showing 1 changed file with 10 additions and 11 deletions.
21 changes: 10 additions & 11 deletions packages/portal-gun/tests/basic.test.ts
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@
import { loadFixture } from '@inox-tools/astro-tests/astroFixture';
import { parseHTML } from 'linkedom';
import { beforeAll, expect, test } from 'vitest';

const fixture = await loadFixture({
root: './fixture/basic',
root: './fixture/basic',
});

beforeAll(async () => {
await fixture.build({});
await fixture.build({});
});

test('elements are sent across Astro Components', async () => {
const html = await fixture.readFile('header-footer/index.html');
const html = await fixture.readFile('header-footer/index.html');

expect(html).toEqualIgnoringWhitespace(`
expect(html).toEqualIgnoringWhitespace(`
<!doctype html>
<html>
<head>
Expand All @@ -36,9 +35,9 @@ test('elements are sent across Astro Components', async () => {
});

test('portals entries without a landing portal get voided', async () => {
const html = await fixture.readFile('missing-portal/index.html');
const html = await fixture.readFile('missing-portal/index.html');

expect(html).toEqualIgnoringWhitespace(`
expect(html).toEqualIgnoringWhitespace(`
<!doctype html>
<html>
<head>
Expand All @@ -55,9 +54,9 @@ test('portals entries without a landing portal get voided', async () => {
});

test('portal to start and end of identified element', async () => {
const html = await fixture.readFile('id-boundary/index.html');
const html = await fixture.readFile('id-boundary/index.html');

expect(html).toEqualIgnoringWhitespace(`
expect(html).toEqualIgnoringWhitespace(`
<!doctype html>
<html>
<head>
Expand All @@ -78,9 +77,9 @@ test('portal to start and end of identified element', async () => {
});

test('portal to start and end of head and body', async () => {
const html = await fixture.readFile('global-boundary/index.html');
const html = await fixture.readFile('global-boundary/index.html');

expect(html).toEqualIgnoringWhitespace(`
expect(html).toEqualIgnoringWhitespace(`
<!doctype html>
<html>
<head>
Expand Down

0 comments on commit 39fca61

Please sign in to comment.