From 7654ede904128eec943807513c249b40ccedfbd9 Mon Sep 17 00:00:00 2001 From: Tommy Date: Fri, 22 Oct 2021 10:30:17 +0100 Subject: [PATCH] Update tests to use new selectors, implement reporting . Use accessible ID's to identify elements . Implement reporting . Clean up . Input more notes in README.md --- .../src/components/NavigationCards.tsx | 2 +- tauri-wallet/src/components/NymCard.tsx | 1 + tauri-wallet/src/routes/delegate/index.tsx | 2 +- tauri-wallet/src/routes/send/SendReview.tsx | 9 +- tauri-wallet/src/routes/sign-in.tsx | 2 +- tauri-wallet/webdriver/.gitignore | 1 + tauri-wallet/webdriver/README.md | 39 ++++--- .../common/constants/text-constants.js | 4 +- .../webdriver/common/data/user-data.js | 8 -- .../webdriver/common/data/user-data.json | 9 ++ tauri-wallet/webdriver/package.json | 10 +- .../webdriver/tests/pages/wallet.bond.js | 69 +++--------- .../webdriver/tests/pages/wallet.create.js | 21 ++-- .../webdriver/tests/pages/wallet.delegate.js | 89 +++------------ .../webdriver/tests/pages/wallet.homepage.js | 54 ++------- .../webdriver/tests/pages/wallet.login.js | 38 ++----- .../webdriver/tests/pages/wallet.receive.js | 32 ++---- .../webdriver/tests/pages/wallet.send.js | 86 +++------------ .../tests/pages/wallet.undelegate.js | 23 +--- .../specs/existinguser/test.wallet.bond.js | 8 +- .../existinguser/test.wallet.delegate.js | 84 +++++++------- .../specs/existinguser/test.wallet.home.js | 55 ++++----- .../specs/existinguser/test.wallet.receive.js | 30 +++-- .../specs/existinguser/test.wallet.send.js | 32 +++--- .../existinguser/test.wallet.undelegate.js | 30 +++-- .../tests/specs/newuser/test.wallet.create.js | 46 +++++--- tauri-wallet/webdriver/wdio.conf.cjs | 104 ++++++++++-------- wallet-web/pages/send.tsx | 1 + 28 files changed, 344 insertions(+), 545 deletions(-) delete mode 100644 tauri-wallet/webdriver/common/data/user-data.js create mode 100644 tauri-wallet/webdriver/common/data/user-data.json diff --git a/tauri-wallet/src/components/NavigationCards.tsx b/tauri-wallet/src/components/NavigationCards.tsx index 82e993eb92..05fa151c5e 100644 --- a/tauri-wallet/src/components/NavigationCards.tsx +++ b/tauri-wallet/src/components/NavigationCards.tsx @@ -43,7 +43,7 @@ export const BalanceCard = () => { {getBalance.error} ) : ( - + {getBalance.balance?.printable_balance} )} diff --git a/tauri-wallet/src/components/NymCard.tsx b/tauri-wallet/src/components/NymCard.tsx index c77fe38359..162610b15b 100644 --- a/tauri-wallet/src/components/NymCard.tsx +++ b/tauri-wallet/src/components/NymCard.tsx @@ -13,6 +13,7 @@ export const NymCard: React.FC<{ { }} >