chore: enable dumpio test only on old headless (#10922)

This commit is contained in:
jrandolf 2023-09-18 08:56:18 +02:00 committed by GitHub
parent 1283ca5bcf
commit 5e9bc691ed
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 17 deletions

View File

@ -3989,18 +3989,6 @@
"parameters": ["cdp", "chrome", "new-headless"], "parameters": ["cdp", "chrome", "new-headless"],
"expectations": ["FAIL", "PASS"] "expectations": ["FAIL", "PASS"]
}, },
{
"testIdPattern": "[fixtures.spec] Fixtures dumpio option should work with pipe option",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["cdp", "chrome", "headful"],
"expectations": ["FAIL", "PASS"]
},
{
"testIdPattern": "[fixtures.spec] Fixtures dumpio option should work with pipe option",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["cdp", "chrome", "new-headless"],
"expectations": ["FAIL", "PASS"]
},
{ {
"testIdPattern": "[headful.spec] headful tests HEADFUL OOPIF: should expose events within OOPIFs", "testIdPattern": "[headful.spec] headful tests HEADFUL OOPIF: should expose events within OOPIFs",
"platforms": ["linux"], "platforms": ["linux"],

View File

@ -29,7 +29,7 @@ describe('Fixtures', function () {
it('dumpio option should work with pipe option', async () => { it('dumpio option should work with pipe option', async () => {
const {defaultBrowserOptions, puppeteerPath, headless} = const {defaultBrowserOptions, puppeteerPath, headless} =
await getTestState(); await getTestState();
if (headless === 'new') { if (headless !== 'true') {
// This test only works in the old headless mode. // This test only works in the old headless mode.
return; return;
} }
@ -46,7 +46,7 @@ describe('Fixtures', function () {
JSON.stringify(options), JSON.stringify(options),
]); ]);
res.stderr.on('data', data => { res.stderr.on('data', data => {
return (dumpioData += data.toString('utf8')); dumpioData += data.toString('utf8');
}); });
await new Promise(resolve => { await new Promise(resolve => {
return res.on('close', resolve); return res.on('close', resolve);
@ -65,7 +65,7 @@ describe('Fixtures', function () {
JSON.stringify(options), JSON.stringify(options),
]); ]);
res.stderr.on('data', data => { res.stderr.on('data', data => {
return (dumpioData += data.toString('utf8')); dumpioData += data.toString('utf8');
}); });
await new Promise(resolve => { await new Promise(resolve => {
return res.on('close', resolve); return res.on('close', resolve);
@ -88,7 +88,7 @@ describe('Fixtures', function () {
]); ]);
let wsEndPointCallback: (value: string) => void; let wsEndPointCallback: (value: string) => void;
const wsEndPointPromise = new Promise<string>(x => { const wsEndPointPromise = new Promise<string>(x => {
return (wsEndPointCallback = x); wsEndPointCallback = x;
}); });
let output = ''; let output = '';
res.stdout.on('data', data => { res.stdout.on('data', data => {
@ -103,7 +103,7 @@ describe('Fixtures', function () {
const promises = [ const promises = [
waitEvent(browser, 'disconnected'), waitEvent(browser, 'disconnected'),
new Promise(resolve => { new Promise(resolve => {
return res.on('close', resolve); res.on('close', resolve);
}), }),
]; ];
if (process.platform === 'win32') { if (process.platform === 'win32') {