Skip to content
Snippets Groups Projects
Commit 19dc09ea authored by François Grand's avatar François Grand
Browse files

test(e2e): MacroRugoRemous: check select empty message when no PAM exists in the session

refs #609
parent c9d6cab6
No related branches found
No related tags found
No related merge requests found
import { ListPage } from "./list.po";
import { browser, by, element } from "protractor";
import { PreferencesPage } from "./preferences.po";
import { Navbar } from "./navbar.po";
describe("MacroRugoRemous - ", () => {
let prefPage: PreferencesPage;
let listPage: ListPage;
let navBar: Navbar;
beforeAll(() => {
prefPage = new PreferencesPage();
listPage = new ListPage();
navBar = new Navbar();
// browser.manage().window().setPosition(2000, 30);
});
beforeEach(async () => {
// disable evil option "empty fields on module creation"
await prefPage.navigateTo();
await browser.sleep(200);
await prefPage.disableEvilEmptyFields();
await browser.sleep(200);
});
it("check select empty message is present when no PAM is in the session", async () => {
// start page
await navBar.clickNewCalculatorButton();
await browser.sleep(200);
// MacroRugoRemous calculator
await listPage.clickMenuEntryForCalcType(37);
browser.sleep(200);
const emptyMsg = element(by.css("div .message-when-empty"));
expect(await emptyMsg.isPresent()).toBe(true);
});
it("check select empty message is not present when a PAM exists in the session", async () => {
// start page
await navBar.clickNewCalculatorButton();
await browser.sleep(200);
// PAM calculator
await listPage.clickMenuEntryForCalcType(11);
browser.sleep(200);
await navBar.clickNewCalculatorButton();
await browser.sleep(200);
// MacroRugoRemous calculator
await listPage.clickMenuEntryForCalcType(37);
browser.sleep(200);
const emptyMsg = element(by.css("div .message-when-empty"));
expect(await emptyMsg.isPresent()).toBe(false);
});
});
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