Tests: Update page model and testcafe config
This commit is contained in:
parent
fb42113207
commit
7b4c2d2fb2
|
@ -6,6 +6,10 @@ fixture`Test albums`.page`${testcafeconfig.url}`;
|
|||
|
||||
const page = new Page();
|
||||
|
||||
test.meta("testID", "authentication-000")("Time to start instance (will be marked as unstable)", async (t) => {
|
||||
await t.wait(5000);
|
||||
});
|
||||
|
||||
test.meta("testID", "albums-001")("Create/delete album on /albums", async (t) => {
|
||||
await page.openNav();
|
||||
await t.click(Selector(".nav-albums"));
|
||||
|
|
|
@ -205,8 +205,11 @@ export default class Page {
|
|||
}
|
||||
}
|
||||
|
||||
async login(password) {
|
||||
await t.typeText(Selector('input[type="password"]'), password).pressKey("enter");
|
||||
async login(username, password) {
|
||||
await t
|
||||
.typeText(Selector(".input-name input"), username, { replace: true, timeout: 5000 })
|
||||
.typeText(Selector(".input-password input"), password, { replace: true })
|
||||
.click(Selector(".action-confirm"));
|
||||
}
|
||||
|
||||
async logout() {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{
|
||||
|
||||
"url": "localhost:2343/photos"
|
||||
"url": "localhost:2343/browse"
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue