aboutsummaryrefslogtreecommitdiffstats
path: root/test/integration/lib/send-new-ui.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/integration/lib/send-new-ui.js')
-rw-r--r--test/integration/lib/send-new-ui.js16
1 files changed, 7 insertions, 9 deletions
diff --git a/test/integration/lib/send-new-ui.js b/test/integration/lib/send-new-ui.js
index 176907926..241358135 100644
--- a/test/integration/lib/send-new-ui.js
+++ b/test/integration/lib/send-new-ui.js
@@ -5,8 +5,6 @@ const {
findAsync,
} = require('../../lib/util')
-const PASSWORD = 'password123'
-
QUnit.module('new ui send flow')
QUnit.test('successful send flow', (assert) => {
@@ -54,7 +52,7 @@ async function customizeGas (assert, price, limit, ethFee, usdFee) {
)
}
-async function runSendFlowTest(assert, done) {
+async function runSendFlowTest (assert, done) {
console.log('*** start runSendFlowTest')
const selectState = await queryAsync($, 'select')
selectState.val('send new ui')
@@ -87,7 +85,7 @@ async function runSendFlowTest(assert, done) {
sendFromFieldItemAddress = await queryAsync($, '.account-list-item__account-name')
assert.equal(sendFromFieldItemAddress[0].textContent, 'Send Account 2', 'send from field dropdown changes account name')
- let sendToFieldInput = await queryAsync($, '.send-v2__to-autocomplete__input')
+ const sendToFieldInput = await queryAsync($, '.send-v2__to-autocomplete__input')
sendToFieldInput[0].focus()
const sendToDropdownList = await queryAsync($, '.send-v2__from-dropdown__list')
@@ -101,7 +99,7 @@ async function runSendFlowTest(assert, done) {
const sendAmountField = await queryAsync($, '.send-v2__form-row:eq(2)')
sendAmountField.find('.currency-display')[0].click()
- const sendAmountFieldInput = await findAsync(sendAmountField, 'input:text')
+ const sendAmountFieldInput = await findAsync(sendAmountField, '.currency-display__input')
sendAmountFieldInput.val('5.1')
reactTriggerChange(sendAmountField.find('input')[0])
@@ -117,17 +115,17 @@ async function runSendFlowTest(assert, done) {
const sendGasField = await queryAsync($, '.send-v2__gas-fee-display')
assert.equal(
sendGasField.find('.currency-display__input-wrapper > input').val(),
- '0.000198',
+ '0.000021',
'send gas field should show estimated gas total'
)
assert.equal(
sendGasField.find('.currency-display__converted-value')[0].textContent,
- '$0.24 USD',
+ '$0.03 USD',
'send gas field should show estimated gas total converted to USD'
)
await customizeGas(assert, 0, 21000, '0', '$0.00 USD')
- await customizeGas(assert, 500, 60000, '0.003', '$3.60 USD')
+ await customizeGas(assert, 500, 60000, '0.03', '$36.03 USD')
const sendButton = await queryAsync($, 'button.btn-primary.btn--large.page-container__footer-button')
assert.equal(sendButton[0].textContent, 'Next', 'next button rendered')
@@ -165,7 +163,7 @@ async function runSendFlowTest(assert, done) {
const sendAmountFieldInEdit = await queryAsync($, '.send-v2__form-row:eq(2)')
sendAmountFieldInEdit.find('.currency-display')[0].click()
- const sendAmountFieldInputInEdit = sendAmountFieldInEdit.find('input:text')
+ const sendAmountFieldInputInEdit = sendAmountFieldInEdit.find('.currency-display__input')
sendAmountFieldInputInEdit.val('1.0')
reactTriggerChange(sendAmountFieldInputInEdit[0])