mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00
test: follow up with chromiunm test fixes
This commit is contained in:
parent
58336d3eb9
commit
26e96bf591
@ -19,12 +19,14 @@ const util = require('util');
|
|||||||
const fs = require('fs');
|
const fs = require('fs');
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
const os = require('os');
|
const os = require('os');
|
||||||
|
const readFileAsync = util.promisify(fs.readFile);
|
||||||
const rmAsync = util.promisify(require('rimraf'));
|
const rmAsync = util.promisify(require('rimraf'));
|
||||||
const mkdtempAsync = util.promisify(fs.mkdtemp);
|
const mkdtempAsync = util.promisify(fs.mkdtemp);
|
||||||
|
const statAsync = util.promisify(fs.stat);
|
||||||
|
|
||||||
const TMP_FOLDER = path.join(os.tmpdir(), 'pptr_tmp_folder-');
|
const TMP_FOLDER = path.join(os.tmpdir(), 'pptr_tmp_folder-');
|
||||||
|
|
||||||
module.exports.addTests = function({testRunner, expect, defaultBrowserOptions, playwright, WEBKIT, FFOX, WIN}) {
|
module.exports.addTests = function({testRunner, expect, defaultBrowserOptions, playwright, WIN}) {
|
||||||
const {describe, xdescribe, fdescribe} = testRunner;
|
const {describe, xdescribe, fdescribe} = testRunner;
|
||||||
const {it, fit, xit} = testRunner;
|
const {it, fit, xit} = testRunner;
|
||||||
const {beforeAll, beforeEach, afterAll, afterEach} = testRunner;
|
const {beforeAll, beforeEach, afterAll, afterEach} = testRunner;
|
||||||
@ -238,7 +240,7 @@ module.exports.addTests = function({testRunner, expect, defaultBrowserOptions, p
|
|||||||
});
|
});
|
||||||
|
|
||||||
describe('BrowserFetcher', function() {
|
describe('BrowserFetcher', function() {
|
||||||
it.skip(WEBKIT || FFOX)('should download and extract linux binary', async({server}) => {
|
it('should download and extract linux binary', async({server}) => {
|
||||||
const downloadsFolder = await mkdtempAsync(TMP_FOLDER);
|
const downloadsFolder = await mkdtempAsync(TMP_FOLDER);
|
||||||
const browserFetcher = playwright.createBrowserFetcher({
|
const browserFetcher = playwright.createBrowserFetcher({
|
||||||
platform: 'linux',
|
platform: 'linux',
|
||||||
@ -251,7 +253,7 @@ module.exports.addTests = function({testRunner, expect, defaultBrowserOptions, p
|
|||||||
});
|
});
|
||||||
|
|
||||||
expect(revisionInfo.local).toBe(false);
|
expect(revisionInfo.local).toBe(false);
|
||||||
expect(browserFetcher.platform()).toBe('linux');
|
expect(browserFetcher._platform).toBe('linux');
|
||||||
expect(await browserFetcher.canDownload('100000')).toBe(false);
|
expect(await browserFetcher.canDownload('100000')).toBe(false);
|
||||||
expect(await browserFetcher.canDownload('123456')).toBe(true);
|
expect(await browserFetcher.canDownload('123456')).toBe(true);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user