Skip to content

Commit

Permalink
nit
Browse files Browse the repository at this point in the history
  • Loading branch information
mxschmitt committed Feb 5, 2024
1 parent c12de6b commit c33b032
Showing 1 changed file with 0 additions and 25 deletions.
25 changes: 0 additions & 25 deletions tests/profile-discovery.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,28 +75,3 @@ test('should create run & debug profile per project', async ({ activate }, testI
> playwright list-files -c playwright.config.js
`);
});

test('retain run profile instances of reload', async ({ activate }, testInfo) => {
const { testController, workspaceFolder } = await activate({
'playwright.config.js': `module.exports = {
projects: [{ name: 'projectA' }, { name: 'projectB' }]
}`
}, { rootDir: testInfo.outputPath('workspace') });

const runProfiles = new Set(testController.runProfiles);

await workspaceFolder.changeFile('playwright.config.js', `module.exports = {
projects: [{ name: 'projectA' }, { name: 'projectC' }, { name: 'projectD' }]
}`);

while (testController.runProfiles.length !== 6)
await new Promise(f => setTimeout(f, 100));

let retained = 0;
for (const profile of testController.runProfiles) {
if (runProfiles.has(profile))
++retained;
}

expect(retained).toBe(2); // Run & Debug projects from project A.
});

0 comments on commit c33b032

Please sign in to comment.