Skip to content
Snippets Groups Projects
Commit 160f9063 authored by mathias.chouet's avatar mathias.chouet
Browse files

Updated e2e for Solveur compliance

parent 8682553e
No related branches found
No related tags found
1 merge request!65Resolve "Solveur multi-modules"
......@@ -18,7 +18,12 @@ describe("ngHyd − calculate all parameters of all calculators", () => {
});
// get calculators list (IDs) @TODO read it from config, but can't import jalhyd here :/
const calcTypes = [ 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 15, 17, 18, 19, 20, 21 ];
const calcTypes = [
0, 1, 2, 3, 4, 5, 6, 8, 9, 10,
11, 12, 13, 15, 17, 18, 19, 20,
21,
// 22 - Solveur is not calculated here because it is not independent
];
// for each calculator
for (const ct of calcTypes) {
......
......@@ -25,7 +25,7 @@ describe("ngHyd − check translation of all calculators", () => {
});
// get calculators list (IDs) @TODO read it from config, but can't import jalhyd here :/
const calcTypes = [ 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 15, 17, 18, 19, 20, 21 ];
const calcTypes = [ 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 15, 17, 18, 19, 20, 21, 22 ];
// options of "Language" selector on preferences page
const langs = [ "English", "Français" ];
......@@ -67,12 +67,13 @@ describe("ngHyd − check translation of all calculators", () => {
// check that "compute" button is active
const calcButton = calcPage.getCalculateButton();
const disabledState = await calcButton.getAttribute("disabled");
expect(disabledState).not.toBe("true");
// click "compute" button
await calcButton.click();
// check that result is not empty
const hasResults = await calcPage.hasResults();
expect(hasResults).toBe(true);
if (! disabledState) {
// click "compute" button
await calcButton.click();
// check that result is not empty
const hasResults = await calcPage.hasResults();
expect(hasResults).toBe(true);
}
// check absence of "*** message not found" in whole DOM
expect(await browser.getPageSource()).not.toContain("*** message not found");
......
......@@ -18,7 +18,12 @@ describe("ngHyd − clone all calculators with all possible <select> values", ()
});
// get calculators list (IDs) @TODO read it from config, but can't import jalhyd here :/
const calcTypes = [ 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 15, 17, 18, 19, 20, 21 ];
const calcTypes = [
0, 1, 2, 3, 4, 5, 6, 8, 9, 10,
11, 12, 13, 15, 17, 18, 19, 20,
21,
// 22 - Solveur is not cloned here because it is not independent
];
// for each calculator
for (const ct of calcTypes) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment