Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Playwright port conflict #15

Merged
merged 2 commits into from
Apr 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,8 @@ const config: PlaywrightTestConfig = {

/* Run your local dev server before starting the tests */
webServer: {
command: 'yarn express',
port: 3000,
command: 'PORT=3001 yarn express',
port: 3001,
},
};

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/ajax1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const AJAX_DELAY = 500; // see text-mutation.html

test.describe('TTVC', () => {
test('a mutation triggered after an AJAX request', async ({page}) => {
await page.goto(`http://localhost:3000/test/ajax1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/ajax1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/ajax2/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const AJAX_DELAY = 500; // see text-mutation.html

test.describe('TTVC', () => {
test('a text-only mutation triggered after AJAX', async ({page}) => {
await page.goto(`http://localhost:3000/test/ajax2?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/ajax2?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/ajax3/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const AJAX_DELAY = 500; // see text-mutation.html

test.describe('TTVC', () => {
test('a mutation triggered after an AJAX request', async ({page}) => {
await page.goto(`http://localhost:3000/test/ajax3?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/ajax3?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/composition1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const SCRIPT_DELAY = 500;

test.describe('TTVC', () => {
test('ajax request > script load > mutation + background lazyloaded script', async ({page}) => {
await page.goto(`http://localhost:3000/test/composition1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/composition1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/composition2/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ test.describe('TTVC', () => {
test('script load > ajax request > CPU work > script load > mutation + background lazyloaded script', async ({
page,
}) => {
await page.goto(`http://localhost:3000/test/composition2?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/composition2?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/composition3/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const SCRIPT_DELAY = 500;

test.describe('TTVC', () => {
test('script load > ajax request > CPU work > script load > mutation', async ({page}) => {
await page.goto(`http://localhost:3000/test/composition3?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/composition3?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/cpu1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const CPU_DELAY = 500;

test.describe('TTVC', () => {
test('CPU load followed by a mutation', async ({page}) => {
await page.goto(`http://localhost:3000/test/cpu1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/cpu1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/error1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const IMAGE_DELAY = 500;

test.describe('TTVC', () => {
test('an image that fails to load', async ({page}) => {
await page.goto(`http://localhost:3000/test/error1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/error1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/error2/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const IMAGE_DELAY = 500;

test.describe('TTVC', () => {
test('an appended image that fails to load + background lazyloaded script', async ({page}) => {
await page.goto(`http://localhost:3000/test/error2?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/error2?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/error3/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ test.describe('TTVC', () => {
test('an appended script that errors (404) + a mutation + background lazyloaded script', async ({
page,
}) => {
await page.goto(`http://localhost:3000/test/error3?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/error3?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/iframe1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const IFRAME_DELAY = 500;
test.describe('TTVC', () => {
test('a static document with an iframe', async ({page}) => {
test.fail(); // TODO: iframe content is not accounted for
await page.goto(`http://localhost:3000/test/static1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/static1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/images1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const IMAGE_DELAY = 500;

test.describe('TTVC', () => {
test('a single loading image', async ({page}) => {
await page.goto(`http://localhost:3000/test/images1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/images1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/images2/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const IMAGE_DELAY = 500;

test.describe('TTVC', () => {
test('a loading image with a concurrent mutation', async ({page}) => {
await page.goto(`http://localhost:3000/test/images2?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/images2?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/images3/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const LONGEST_IMAGE_DELAY = 400;

test.describe('TTVC', () => {
test('four loading images with a concurrent mutation', async ({page}) => {
await page.goto(`http://localhost:3000/test/images3?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/images3?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/images4/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const LONGEST_IMAGE_DELAY = 400;

test.describe('TTVC', () => {
test('four loading images with a concurrent mutation and a script tag', async ({page}) => {
await page.goto(`http://localhost:3000/test/images4?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/images4?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/images5/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const IMAGE_DELAY = 500;

test.describe('TTVC', () => {
test('one loading image and one image w/ inline data url', async ({page}) => {
await page.goto(`http://localhost:3000/test/images5?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/images5?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/interaction1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import {entryCountIs, getEntries} from '../../util/entries';

test.describe('TTVC', () => {
test('user clicks before page completes loading', async ({page}) => {
await page.goto(`http://localhost:3000/test/interaction1`, {
await page.goto(`/test/interaction1`, {
waitUntil: 'domcontentloaded',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/interaction2/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import {entryCountIs, getEntries} from '../../util/entries';

test.describe('TTVC', () => {
test('tab is backgrounded before page completes loading', async ({page}) => {
await page.goto(`http://localhost:3000/test/interaction1`, {
await page.goto(`/test/interaction1`, {
waitUntil: 'domcontentloaded',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/invisible1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const IMAGE_DELAY = 500;

test.describe('TTVC', () => {
test('a single image with style="display: none"', async ({page}) => {
await page.goto(`http://localhost:3000/test/invisible1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/invisible1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/invisible2/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const PAGELOAD_DELAY = 200;

test.describe('TTVC', () => {
test('a single image with style="display: none" and a simultaneous mutation', async ({page}) => {
await page.goto(`http://localhost:3000/test/invisible2?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/invisible2?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/invisible3/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ test.describe('TTVC', () => {
test('a single image with style="display: none" + a mutation + background lazyload', async ({
page,
}) => {
await page.goto(`http://localhost:3000/test/invisible3?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/invisible3?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/invisible4/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const SCRIPT_DELAY = 200;

test.describe('TTVC', () => {
test('a visible mutation + an invisible mutation (display:none)', async ({page}) => {
await page.goto(`http://localhost:3000/test/invisible4?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/invisible4?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/invisible5/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const SCRIPT_DELAY = 200;

test.describe('TTVC', () => {
test('a visible mutation + a mutation with invisible parent', async ({page}) => {
await page.goto(`http://localhost:3000/test/invisible5?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/invisible5?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/invisible6/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const SCRIPT_DELAY = 200;

test.describe('TTVC', () => {
test('a visible mutation + an invisible mutation (left:-1000px)', async ({page}) => {
await page.goto(`http://localhost:3000/test/invisible6?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/invisible6?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/invisible7/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const SCRIPT_DELAY = 200;

test.describe('TTVC', () => {
test('a visible mutation + an invisible mutation (below the fold)', async ({page}) => {
await page.goto(`http://localhost:3000/test/invisible7?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/invisible7?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/react1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const PAGELOAD_DELAY = 200;

test.describe('TTVC', () => {
test('a simple react application', async ({page}) => {
await page.goto(`http://localhost:3000/test/static1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/static1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/react2/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const IMAGE_DELAY = 500;

test.describe('TTVC', () => {
test('a simple react application with an image', async ({page}) => {
await page.goto(`http://localhost:3000/test/react2?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/react2?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/scripts1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const SCRIPT_DELAY = 500;

test.describe('TTVC', () => {
test('a single loading script tag and then a mutation', async ({page}) => {
await page.goto(`http://localhost:3000/test/scripts1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/scripts1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/scripts2/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const FIRST_SCRIPT_DELAY = 500;

test.describe('TTVC', () => {
test('two loading script tags, the first triggers a mutation', async ({page}) => {
await page.goto(`http://localhost:3000/test/scripts2?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/scripts2?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/scripts3/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const FIRST_SCRIPT_DELAY = 500;

test.describe('TTVC', () => {
test('two appended script tags, the first triggers a mutation', async ({page}) => {
await page.goto(`http://localhost:3000/test/scripts3?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/scripts3?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/static1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const PAGELOAD_DELAY = 200;

test.describe('TTVC', () => {
test('a static HTML document', async ({page}) => {
await page.goto(`http://localhost:3000/test/static1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/static1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/stylesheet1/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const STYLESHEET_DELAY = 500;
test.describe('TTVC', () => {
test('a static HTML document', async ({page}) => {
test.fail(); // ttvc doesn't account for stylesheets yet
await page.goto(`http://localhost:3000/test/stylesheet1?delay=${PAGELOAD_DELAY}`, {
await page.goto(`/test/stylesheet1?delay=${PAGELOAD_DELAY}`, {
waitUntil: 'networkidle',
});

Expand Down