mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
test: add canary specific expectation file (#12383)
This commit is contained in:
20
tools/merge-canary-test-expectations.mjs
Normal file
20
tools/merge-canary-test-expectations.mjs
Normal file
@@ -0,0 +1,20 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright 2024 Google Inc.
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
// Modifies test/TestExpectations.json in place.
|
||||
|
||||
import fs from 'fs';
|
||||
|
||||
const source = 'test/TestExpectations.json';
|
||||
const testExpectations = JSON.parse(fs.readFileSync(source, 'utf-8'));
|
||||
const canaryTestExpectations = JSON.parse(
|
||||
fs.readFileSync('test/CanaryTestExpectations.json', 'utf-8')
|
||||
);
|
||||
|
||||
fs.writeFileSync(
|
||||
source,
|
||||
JSON.stringify([...testExpectations, ...canaryTestExpectations], null, 2)
|
||||
);
|
||||
Reference in New Issue
Block a user