From 8cf30550e31d5acaa8c184d61c3cf6452c125f57 Mon Sep 17 00:00:00 2001 From: Girish Ramakrishnan Date: Tue, 12 May 2026 12:13:21 +0200 Subject: [PATCH] fix tests --- test/test.js | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/test/test.js b/test/test.js index 0ac99dd..63543fd 100644 --- a/test/test.js +++ b/test/test.js @@ -18,10 +18,10 @@ describe('Application life cycle test', function () { }); async function login(uname, pass) { - await goto(`https://${app.fqdn}`, 'css=#user'); - await sendKeys('css=#user', uname); - await sendKeys('css=#password', pass); - await click('xpath=//button[@type="submit"]'); + await goto(`https://${app.fqdn}`, 'label=User'); + await sendKeys('label=User', uname); + await sendKeys('label=Password', pass); + await click('Log In'); await waitFor('Actions'); } @@ -30,12 +30,11 @@ describe('Application life cycle test', function () { } async function addFolder() { - await goto(`https://${app.fqdn}`, 'css=[ng-click*=addFolder]'); - await click('css=[ng-click*=addFolder]'); - await waitFor('css=#folderPath'); - await sendKeys('css=#folderLabel', FOLDER); - await sendKeys('css=#folderPath', `/app/data/${FOLDER}`); - await click('css=[ng-click*=saveFolder]'); + await goto(`https://${app.fqdn}`, /Add Folder/); + await click(/Add Folder/); + await sendKeys('label=Folder Label', FOLDER); + await sendKeys('label=Folder Path', `/app/data/${FOLDER}`); + await click(/Save/); await waitFor(FOLDER); }