T3513
We were double-setting the state here which could have caused some issues. Works now in testing.
Differential D15916
[Cashtab] Correct routing for sending to contact bytesofman on Apr 6 2024, 19:18. Authored by Tags None Subscribers None
Details
T3513 We were double-setting the state here which could have caused some issues. Works now in testing. npm test
Diff Detail
Event TimelineComment Actions Build Bitcoin ABC Diffs / Diff Testing (cashtab-tests) failed.
Failed tests logs: ====== CashTab Unit Tests: <App /> Clicking "reply" on a Cashtab Msg correctly populates the SendXec to address and amount fields ====== Error: expect(element).toHaveValue(5.5) Expected the element to have value: 5.5 Received: 0 at Object.toHaveValue (/work/cashtab/src/components/App/__tests__/App.test.js:463:55) Each failure log is accessible here: Comment Actions Build Bitcoin ABC Diffs / Diff Testing (cashtab-tests) failed.
Failed tests logs: ====== CashTab Unit Tests: <App /> Clicking "reply" on a Cashtab Msg correctly populates the SendXec to address and amount fields ====== Error: expect(element).toHaveValue(5.5) Expected the element to have value: 5.5 Received: 0 at Object.toHaveValue (/work/cashtab/src/components/App/__tests__/App.test.js:463:55) Each failure log is accessible here: Comment Actions Build Bitcoin ABC Diffs / Diff Testing (cashtab-tests) failed.
Failed tests logs: ====== CashTab Unit Tests: <Configure /> We can send a tx to an address in contacts ====== TestingLibraryElementError: Unable to find an accessible element with the role "button" and name `/Contact List/` Here are the accessible roles: img: Name "loading": <span aria-label="loading" class="anticon anticon-loading anticon-spin cashLoadingIcon ant-spin-dot" role="img" /> Name "cashtab": <img alt="cashtab" class="sc-cJOK fmOHit" src="test-file-stub" /> Name "wallet": <span aria-label="wallet" class="anticon anticon-wallet sc-bxivhb iBBRHU" role="img" /> Name "right": <span aria-label="right" class="anticon anticon-right ant-collapse-arrow" role="img" /> Name "contacts": <span aria-label="contacts" class="anticon anticon-contacts sc-bZQynM doPruo" role="img" tabindex="-1" /> Name "dollar": <span aria-label="dollar" class="anticon anticon-dollar sc-htpNat lgbLiL" role="img" /> Name "setting": <span aria-label="setting" class="anticon anticon-setting sc-ifAKCX gjwsUR" role="img" /> Name "lock": <span aria-label="lock" class="anticon anticon-lock" role="img" /> Name "lock": <span aria-label="lock" class="anticon anticon-lock" role="img" /> Name "github": <span aria-label="github" class="anticon anticon-github sc-dxgOiQ bqWUbc" role="img" /> Name "appstore-add": <span aria-label="appstore-add" class="anticon anticon-appstore-add" role="img" style="font-size: 24px;" /> Name "wallet": <span aria-label="wallet" class="anticon anticon-wallet sc-bxivhb sc-jzJRlG kEwEpW" role="img" /> Name "contacts": <span aria-label="contacts" class="anticon anticon-contacts sc-bZQynM sc-cSHVUG fqFTTq" role="img" /> Name "swap": <span aria-label="swap" class="anticon anticon-swap" role="img" style="font-size: 24px;" /> -------------------------------------------------- combobox: Name "": <select class="sc-dRFtgE cbNHwi" id="wallets" name="wallets" /> Name "": <input aria-autocomplete="list" aria-controls="rc_select_TEST_OR_SSR_list" aria-expanded="false" aria-haspopup="listbox" aria-owns="rc_select_TEST_OR_SSR_list" autocomplete="off" class="ant-select-selection-search-input" id="rc_select_TEST_OR_SSR" readonly="" role="combobox" style="opacity: 0;" type="search" unselectable="on" value="" /> -------------------------------------------------- option: Name "Transaction Fixtures": <option class="sc-gkFcWv eLSBtU" value="Transaction Fixtures" /> -------------------------------------------------- link: Name "Backup Wallet": <a href="/backup" /> Name "Contacts": <a href="/contacts" /> Name "": <a class="sc-kgoBCf iOoAuJ" href="https://x.com/cashtabwallet" rel="noreferrer" target="_blank" /> Name "": <a class="sc-kgoBCf iOoAuJ" href="https://www.facebook.com/Cashtab" rel="noreferrer" target="_blank" /> Name "github": <a class="sc-kgoBCf iOoAuJ" href="https://github.com/Bitcoin-ABC/bitcoin-abc/tree/master/cashtab" rel="noreferrer" target="_blank" /> -------------------------------------------------- heading: Name "wallet Manage Wallets": <h2 /> Name "Transaction Fixtures": <h3 class="notranslate" /> Name "Currently active": <h4 /> Name "dollar Fiat Currency": <h2 /> Name "setting General Settings": <h2 /> -------------------------------------------------- button: Name "New Wallet": <button class="sc-krvtoX sc-fOKMvo geyeMN" /> Name "Import Wallet": <button class="sc-krvtoX sc-gHboQg bzRniJ" /> Name "right Saved wallets": <div aria-disabled="false" aria-expanded="true" class="ant-collapse-header" role="button" tabindex="0" /> Name "": <button class="sc-iiUIRa gsJidV" /> Name "": <button class="sc-iiUIRa gsJidV" data-testid="nav-btn-send" /> Name "appstore-add": <button class="sc-iiUIRa gsJidV" data-testid="nav-btn-etokens" /> Name "": <button class="sc-iiUIRa gsJidV" data-testid="nav-btn-receive" /> Name "Wallet Backup wallet": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-backup" /> Name "Contacts contacts": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-contacts" /> Name "Airdrop": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-airdrop" /> Name "Swap swap": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-swap" /> Name "Sign & Verify": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-signverifymsg" /> Name "Settings": <button class="sc-eLdqWK cDUTqc" data-testid="nav-btn-configure" /> -------------------------------------------------- Ignored nodes: comments, script, style <body> <div> <div class="ant-spin-nested-loading css-dev-only-do-not-override-1rqnfsa" > <div> <div aria-busy="true" aria-live="polite" class="ant-spin ant-spin-spinning css-dev-only-do-not-override-1rqnfsa" > <span aria-label="loading" class="anticon anticon-loading anticon-spin cashLoadingIcon ant-spin-dot" role="img" > <svg aria-hidden="true" data-icon="loading" fill="currentColor" focusable="false" height="1em" viewBox="0 0 1024 1024" width="1em" > <path d="M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z" /> </svg> </span> </div> </div> <div class="ant-spin-container ant-spin-blur" > <div class="sc-fEUNkw cpTnRy" > <div class="Toastify" /> <div class="sc-hgRTRy jwDJmd" > <div class="sc-gldTML eTWzxL" > <div class="sc-kcbnda gXdnKy" > <div class="sc-feryYK gDStRo" > <img alt="cashtab" class="sc-cJOK fmOHit" src="test-file-stub" /> <div class="sc-elNKlv hJuTGk" > Settings <svg height="33px" width="30px" /> </div> </div> <div class="sc-hSdWYo dgPahU" data-testid="wallet-info-ctn" > <div class="sc-gbOuXE dgCZG" > <select class="sc-dRFtgE cbNHwi" id="wallets" name="wallets" > <option class="sc-gkFcWv eLSBtU" value="Transaction Fixtures" > Transaction Fixtures </option> </select> <div class="sc-gipzik iHnUKn" > <svg class="sc-htoDjs ipNpSe" style="margin-top: 8px;" /> </div> <div class="sc-eerKOB cvXwwv" > <div class="sc-emmjRN bSWkUh" > <input checked="" class="sc-gFaPwZ iPJMNd" data-testid="show-hide-balance" id="show-hide-balance" name="show-hide-balance" type="checkbox" /> <label class="sc-cpmLhU iUeRKn" for="show-hide-balance" > <span class="sc-dymIpo isbbFI" data-off="" data-on="" /> <span class="sc-bnXvFD cpOMDW" /> </label> </div> </div> </div> <div class="sc-hUfwpO fnMZeg" data-testid="balance-xec" > 9,513.12 XEC </div> <div class="sc-imABML hbRzZi" data-testid="balance-fiat" > $ 0.29 USD </div> <p class="sc-cjHlYL sMCVd" data-testid="ecash-price" > 1 XEC = 0.00003000 USD ... at Object.getElementError (/work/cashtab/node_modules/@testing-library/dom/dist/config.js:37:19) at /work/cashtab/node_modules/@testing-library/dom/dist/query-helpers.js:76:38 at /work/cashtab/node_modules/@testing-library/dom/dist/query-helpers.js:52:17 at /work/cashtab/node_modules/@testing-library/dom/dist/query-helpers.js:95:19 at Object.getByRole (/work/cashtab/src/components/Configure/__tests__/Configure.test.js:180:33) at runNextTicks (node:internal/process/task_queues:60:5) at processTimers (node:internal/timers:511:9) Each failure log is accessible here: Comment Actions Build Bitcoin ABC Diffs / Diff Testing (cashtab-tests) failed.
Failed tests logs: ====== CashTab Unit Tests: <Contacts /> We can send a tx to an address in contacts ====== TestingLibraryElementError: Unable to find an accessible element with the role "button" and name `/Contact List/` Here are the accessible roles: img: Name "loading": <span aria-label="loading" class="anticon anticon-loading anticon-spin cashLoadingIcon ant-spin-dot" role="img" /> Name "cashtab": <img alt="cashtab" class="sc-cJOK fmOHit" src="test-file-stub" /> Name "wallet": <span aria-label="wallet" class="anticon anticon-wallet sc-bxivhb iBBRHU" role="img" /> Name "right": <span aria-label="right" class="anticon anticon-right ant-collapse-arrow" role="img" /> Name "contacts": <span aria-label="contacts" class="anticon anticon-contacts sc-bZQynM doPruo" role="img" tabindex="-1" /> Name "dollar": <span aria-label="dollar" class="anticon anticon-dollar sc-htpNat lgbLiL" role="img" /> Name "setting": <span aria-label="setting" class="anticon anticon-setting sc-ifAKCX gjwsUR" role="img" /> Name "lock": <span aria-label="lock" class="anticon anticon-lock" role="img" /> Name "lock": <span aria-label="lock" class="anticon anticon-lock" role="img" /> Name "github": <span aria-label="github" class="anticon anticon-github sc-dxgOiQ bqWUbc" role="img" /> Name "appstore-add": <span aria-label="appstore-add" class="anticon anticon-appstore-add" role="img" style="font-size: 24px;" /> Name "wallet": <span aria-label="wallet" class="anticon anticon-wallet sc-bxivhb sc-jzJRlG kEwEpW" role="img" /> Name "contacts": <span aria-label="contacts" class="anticon anticon-contacts sc-bZQynM sc-cSHVUG fqFTTq" role="img" /> Name "swap": <span aria-label="swap" class="anticon anticon-swap" role="img" style="font-size: 24px;" /> -------------------------------------------------- combobox: Name "": <select class="sc-dRFtgE cbNHwi" id="wallets" name="wallets" /> Name "": <input aria-autocomplete="list" aria-controls="rc_select_TEST_OR_SSR_list" aria-expanded="false" aria-haspopup="listbox" aria-owns="rc_select_TEST_OR_SSR_list" autocomplete="off" class="ant-select-selection-search-input" id="rc_select_TEST_OR_SSR" readonly="" role="combobox" style="opacity: 0;" type="search" unselectable="on" value="" /> -------------------------------------------------- option: Name "Transaction Fixtures": <option class="sc-gkFcWv eLSBtU" value="Transaction Fixtures" /> -------------------------------------------------- link: Name "Backup Wallet": <a href="/backup" /> Name "Contacts": <a href="/contacts" /> Name "": <a class="sc-kgoBCf iOoAuJ" href="https://x.com/cashtabwallet" rel="noreferrer" target="_blank" /> Name "": <a class="sc-kgoBCf iOoAuJ" href="https://www.facebook.com/Cashtab" rel="noreferrer" target="_blank" /> Name "github": <a class="sc-kgoBCf iOoAuJ" href="https://github.com/Bitcoin-ABC/bitcoin-abc/tree/master/cashtab" rel="noreferrer" target="_blank" /> -------------------------------------------------- heading: Name "wallet Manage Wallets": <h2 /> Name "Transaction Fixtures": <h3 class="notranslate" /> Name "Currently active": <h4 /> Name "dollar Fiat Currency": <h2 /> Name "setting General Settings": <h2 /> -------------------------------------------------- button: Name "New Wallet": <button class="sc-krvtoX sc-fOKMvo geyeMN" /> Name "Import Wallet": <button class="sc-krvtoX sc-gHboQg bzRniJ" /> Name "right Saved wallets": <div aria-disabled="false" aria-expanded="true" class="ant-collapse-header" role="button" tabindex="0" /> Name "": <button class="sc-iiUIRa gsJidV" /> Name "": <button class="sc-iiUIRa gsJidV" data-testid="nav-btn-send" /> Name "appstore-add": <button class="sc-iiUIRa gsJidV" data-testid="nav-btn-etokens" /> Name "": <button class="sc-iiUIRa gsJidV" data-testid="nav-btn-receive" /> Name "Wallet Backup wallet": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-backup" /> Name "Contacts contacts": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-contacts" /> Name "Airdrop": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-airdrop" /> Name "Swap swap": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-swap" /> Name "Sign & Verify": <button class="sc-eLdqWK kirUVt" data-testid="nav-btn-signverifymsg" /> Name "Settings": <button class="sc-eLdqWK cDUTqc" data-testid="nav-btn-configure" /> -------------------------------------------------- Ignored nodes: comments, script, style <body> <div> <div class="ant-spin-nested-loading css-dev-only-do-not-override-1rqnfsa" > <div> <div aria-busy="true" aria-live="polite" class="ant-spin ant-spin-spinning css-dev-only-do-not-override-1rqnfsa" > <span aria-label="loading" class="anticon anticon-loading anticon-spin cashLoadingIcon ant-spin-dot" role="img" > <svg aria-hidden="true" data-icon="loading" fill="currentColor" focusable="false" height="1em" viewBox="0 0 1024 1024" width="1em" > <path d="M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z" /> </svg> </span> </div> </div> <div class="ant-spin-container ant-spin-blur" > <div class="sc-fEUNkw cpTnRy" > <div class="Toastify" /> <div class="sc-hgRTRy jwDJmd" > <div class="sc-gldTML eTWzxL" > <div class="sc-kcbnda gXdnKy" > <div class="sc-feryYK gDStRo" > <img alt="cashtab" class="sc-cJOK fmOHit" src="test-file-stub" /> <div class="sc-elNKlv hJuTGk" > Settings <svg height="33px" width="30px" /> </div> </div> <div class="sc-hSdWYo dgPahU" data-testid="wallet-info-ctn" > <div class="sc-gbOuXE dgCZG" > <select class="sc-dRFtgE cbNHwi" id="wallets" name="wallets" > <option class="sc-gkFcWv eLSBtU" value="Transaction Fixtures" > Transaction Fixtures </option> </select> <div class="sc-gipzik iHnUKn" > <svg class="sc-htoDjs ipNpSe" style="margin-top: 8px;" /> </div> <div class="sc-eerKOB cvXwwv" > <div class="sc-emmjRN bSWkUh" > <input checked="" class="sc-gFaPwZ iPJMNd" data-testid="show-hide-balance" id="show-hide-balance" name="show-hide-balance" type="checkbox" /> <label class="sc-cpmLhU iUeRKn" for="show-hide-balance" > <span class="sc-dymIpo isbbFI" data-off="" data-on="" /> <span class="sc-bnXvFD cpOMDW" /> </label> </div> </div> </div> <div class="sc-hUfwpO fnMZeg" data-testid="balance-xec" > 9,513.12 XEC </div> <div class="sc-imABML hbRzZi" data-testid="balance-fiat" > $ 0.29 USD </div> <p class="sc-cjHlYL sMCVd" data-testid="ecash-price" > 1 XEC = 0.00003000 USD ... at Object.getElementError (/work/cashtab/node_modules/@testing-library/dom/dist/config.js:37:19) at /work/cashtab/node_modules/@testing-library/dom/dist/query-helpers.js:76:38 at /work/cashtab/node_modules/@testing-library/dom/dist/query-helpers.js:52:17 at /work/cashtab/node_modules/@testing-library/dom/dist/query-helpers.js:95:19 at Object.getByRole (/work/cashtab/src/components/Contacts/__tests__/index.test.js:299:33) at runNextTicks (node:internal/process/task_queues:60:5) at processTimers (node:internal/timers:511:9) Each failure log is accessible here: |