aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/components/gas-customization/gas-modal-page-container/tests
diff options
context:
space:
mode:
authorDan J Miller <danjm.com@gmail.com>2018-12-11 05:51:00 +0800
committerDan Finlay <542863+danfinlay@users.noreply.github.com>2018-12-11 05:51:00 +0800
commit1fbdce8916151df2b31eebc5de29a1365e5dadff (patch)
tree2333aa889dd6a6ec83a1665591006daca8e68859 /ui/app/components/gas-customization/gas-modal-page-container/tests
parent49971e9ec250888746546f62fa176ed129bf9c74 (diff)
downloadtangerine-wallet-browser-1fbdce8916151df2b31eebc5de29a1365e5dadff.tar.gz
tangerine-wallet-browser-1fbdce8916151df2b31eebc5de29a1365e5dadff.tar.zst
tangerine-wallet-browser-1fbdce8916151df2b31eebc5de29a1365e5dadff.zip
Improve ux for low gas price set (#5862)
* Show user warning if they set gas price below safelow minimum, error if 0. * Properly cache basic price estimate data. * Default retry price to recommended price if original price was 0x0 * Use mock fetch in send-new-ui integration tests.
Diffstat (limited to 'ui/app/components/gas-customization/gas-modal-page-container/tests')
-rw-r--r--ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-component.test.js1
-rw-r--r--ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-container.test.js4
2 files changed, 4 insertions, 1 deletions
diff --git a/ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-component.test.js b/ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-component.test.js
index 2ba2fa9e7..f068c40d0 100644
--- a/ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-component.test.js
+++ b/ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-component.test.js
@@ -78,6 +78,7 @@ describe('GasModalPageContainer Component', function () {
customGasPriceInHex={'mockCustomGasPriceInHex'}
customGasLimitInHex={'mockCustomGasLimitInHex'}
insufficientBalance={false}
+ disableSave={false}
/>, { context: { t: (str1, str2) => str2 ? str1 + str2 : str1 } })
})
diff --git a/ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-container.test.js b/ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-container.test.js
index 512832866..077ec471d 100644
--- a/ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-container.test.js
+++ b/ui/app/components/gas-customization/gas-modal-page-container/tests/gas-modal-page-container-container.test.js
@@ -75,6 +75,7 @@ describe('gas-modal-page-container container', () => {
gas: {
basicEstimates: {
blockTime: 12,
+ safeLow: 2,
},
customData: {
limit: 'aaaaaaaa',
@@ -107,9 +108,10 @@ describe('gas-modal-page-container container', () => {
blockTime: 12,
customModalGasLimitInHex: 'aaaaaaaa',
customModalGasPriceInHex: 'ffffffff',
+ customPriceIsSafe: true,
gasChartProps: {
'currentPrice': 4.294967295,
- estimatedTimes: ['31', '62', '93', '124'],
+ estimatedTimes: [31, 62, 93, 124],
estimatedTimesMax: '31',
gasPrices: [3, 4, 5, 6],
gasPricesMax: 6,