Skip to content

Commit

Permalink
update UI functional test (#2747)
Browse files Browse the repository at this point in the history
* update UI functional test
* update chromedriver package

---------

Signed-off-by: craman <[email protected]>
Co-authored-by: craman <[email protected]>
  • Loading branch information
chandrasekhar1996 and craman committed Sep 29, 2024
1 parent ec3530a commit 09f164c
Show file tree
Hide file tree
Showing 4 changed files with 224 additions and 150 deletions.
107 changes: 90 additions & 17 deletions ui/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@
"@wdio/spec-reporter": "8.31.0",
"babel-jest": "29.7.0",
"babel-preset-current-node-syntax": "1.0.1",
"chromedriver": "120",
"chromedriver": "129",
"dotenv": "16.0.2",
"expect": "29.0.3",
"expect-webdriverio": "4.11.2",
Expand Down
12 changes: 6 additions & 6 deletions ui/src/__tests__/spec/tests/domain.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ describe('Domain', () => {
await browser.waitUntil(async () => await pocAnchor.isClickable());
await pocAnchor.click();
let userInput = await $('input[name="poc-name"]');
await userInput.addValue('jtsang01');
let userOption = await $('div*=Jimmy Tsang [user.jtsang01]');
await userInput.addValue('craman');
let userOption = await $('div*=Chandu Raman [user.craman]');
await userOption.click();
let submitButton = await $('button*=Submit');
await submitButton.click();
await expect(pocAnchor).toHaveTextContaining('Jimmy Tsang');
await expect(pocAnchor).toHaveTextContaining('Chandu Raman');

// test adding security poc
let securityPocAnchor = await $('a[data-testid="security-poc-link"]');
Expand All @@ -43,11 +43,11 @@ describe('Domain', () => {
);
await securityPocAnchor.click();
userInput = await $('input[name="poc-name"]');
await userInput.addValue('jtsang01');
userOption = await $('div*=Jimmy Tsang [user.jtsang01]');
await userInput.addValue('craman');
userOption = await $('div*=Chandu Raman [user.craman]');
await userOption.click();
submitButton = await $('button*=Submit');
await submitButton.click();
await expect(securityPocAnchor).toHaveTextContaining('Jimmy Tsang');
await expect(securityPocAnchor).toHaveTextContaining('Chandu Raman');
});
});
Loading

0 comments on commit 09f164c

Please sign in to comment.