This fix improving logging during running e2e tests. (#39466)
Summary: Motivation was to improve logging for RNTester e2e tests. ## Changelog: [INTERNAL] - Add logging. Pull Request resolved: https://github.com/facebook/react-native/pull/39466 Test Plan: Check logs during 2e automation is running. Reviewed By: NickGerleman Differential Revision: D49499233 Pulled By: cipolleschi fbshipit-source-id: c803fa9227995ed3862b6a919a7590f80e2afc08
This commit is contained in:
Родитель
8e36cc0293
Коммит
e21b3c8296
|
@ -14,4 +14,5 @@ module.exports = {
|
|||
setupFilesAfterEnv: ['./jest.setup.js'],
|
||||
testMatch: ['**/specs/**/*.js'],
|
||||
maxWorkers: 1,
|
||||
verbose: true,
|
||||
};
|
||||
|
|
|
@ -20,19 +20,30 @@ const config = {
|
|||
host: 'localhost',
|
||||
port: 4723,
|
||||
waitforTimeout: 60000,
|
||||
logLevel: 'error',
|
||||
capabilities: {
|
||||
...capabilities,
|
||||
},
|
||||
};
|
||||
|
||||
beforeEach(async () => {
|
||||
// $FlowFixMe
|
||||
let testName: any = expect.getState().currentTestName;
|
||||
console.info(
|
||||
'------------------------------------------------------------ Test is starting... ------------------------------------------------------------',
|
||||
);
|
||||
console.info(
|
||||
'------------------------------ Test name: ' +
|
||||
testName +
|
||||
' ------------------------------',
|
||||
);
|
||||
driver = await wdio.remote(config);
|
||||
});
|
||||
|
||||
afterEach(async () => {
|
||||
console.info('[afterAll] Done with testing!');
|
||||
await driver.deleteSession();
|
||||
console.info(
|
||||
'------------------------------------------------------------ Done with testing. ------------------------------------------------------------',
|
||||
);
|
||||
});
|
||||
|
||||
export {driver};
|
||||
|
|
Загрузка…
Ссылка в новой задаче