Add some 'load scenario' todo tests
This commit is contained in:
parent
16fc0bf793
commit
ac8eb25ac0
@ -259,7 +259,8 @@ if (process.env.NODE_ENV === 'test') {
|
|||||||
res.end("Not found");
|
res.end("Not found");
|
||||||
}
|
}
|
||||||
}).listen(3005, () => {
|
}).listen(3005, () => {
|
||||||
console.log('test server is online');
|
const serverUrl = 'http://localhost:3005';
|
||||||
|
console.log(`Test server running at ${serverUrl}`);
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
buildOptions.define = { 'window.IS_DEV': 'true' };
|
buildOptions.define = { 'window.IS_DEV': 'true' };
|
||||||
@ -321,7 +322,8 @@ if (process.env.NODE_ENV === 'test') {
|
|||||||
req.pipe(proxyReq, { end: true });
|
req.pipe(proxyReq, { end: true });
|
||||||
}
|
}
|
||||||
}).listen(8080, (e) => {
|
}).listen(8080, (e) => {
|
||||||
console.log('server is online', e);
|
const serverUrl = 'http://localhost:8080';
|
||||||
|
console.log(`Development server running at ${serverUrl}`);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -12,8 +12,8 @@
|
|||||||
"selenium-webdriver": "^4.19.0"
|
"selenium-webdriver": "^4.19.0"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "node server.cjs",
|
"start": "node esbuild-server.mjs",
|
||||||
"start:esbuildserver": "node esbuild-server.mjs",
|
"start:esbuild-server": "node server.cjs",
|
||||||
"test:integ": "node ./node_modules/.bin/jest --detectOpenHandles --config jest.config.integ.cjs",
|
"test:integ": "node ./node_modules/.bin/jest --detectOpenHandles --config jest.config.integ.cjs",
|
||||||
"test:integ:debug": "NODE_INSPECT_RESUME_ON_START=1 node inspect ./node_modules/jest/bin/jest.js --config jest.config.integ.cjs --runInBand",
|
"test:integ:debug": "NODE_INSPECT_RESUME_ON_START=1 node inspect ./node_modules/jest/bin/jest.js --config jest.config.integ.cjs --runInBand",
|
||||||
"test": "jest"
|
"test": "jest"
|
||||||
|
23
test/integration/loadScenario.test.js
Normal file
23
test/integration/loadScenario.test.js
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
const { Builder } = require('selenium-webdriver'),
|
||||||
|
chrome = require('selenium-webdriver/chrome.js'),
|
||||||
|
chromeOptions = new chrome.Options();
|
||||||
|
|
||||||
|
chromeOptions.addArguments('--headless', '--disable-gpu', '--no-sandbox');
|
||||||
|
chromeOptions.enableBidi();
|
||||||
|
|
||||||
|
let driver;
|
||||||
|
|
||||||
|
beforeEach(async () => {
|
||||||
|
const builder = new Builder().forBrowser('chrome').setChromeOptions(chromeOptions);
|
||||||
|
driver = builder.build();
|
||||||
|
});
|
||||||
|
|
||||||
|
it.todo('loads default scenario on initial page load');
|
||||||
|
it.todo('loads previously-loaded scenario on page refresh');
|
||||||
|
it.todo('loads built-in scenario from dialog');
|
||||||
|
it.todo('loads custom scenario directly from file');
|
||||||
|
it.todo('loads saved scenario from file');
|
||||||
|
|
||||||
|
afterEach(async () => {
|
||||||
|
await driver.quit();
|
||||||
|
});
|
Loading…
x
Reference in New Issue
Block a user