Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
pedronfigueiredo committed Nov 29, 2024
1 parent 8153d8e commit 2860219
Show file tree
Hide file tree
Showing 11 changed files with 1,423 additions and 748 deletions.
5 changes: 3 additions & 2 deletions test/e2e/tests/tokens/custom-token-send-transfer.spec.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { mockedSourcifyTokenSend } from '../confirmations/transactions/erc20-token-send-redesign.spec';

const { strict: assert } = require('assert');
const {
mockedSourcifyTokenSend,
} = require('../confirmations/transactions/erc20-token-send-redesign.spec');
const {
withFixtures,
defaultGanacheOptions,
Expand Down
2 changes: 0 additions & 2 deletions test/e2e/tests/transaction/change-assets.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { it } from 'mocha';

const { strict: assert } = require('assert');
const {
defaultGanacheOptions,
Expand Down
14 changes: 12 additions & 2 deletions test/e2e/tests/transaction/edit-gas-fee.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,10 +119,10 @@ describe('Editing Confirm Transaction', function () {
await driver.clickElement('[data-testid="edit-gas-fee-item-custom"]');

// enter max fee
await driver.fill('[data-testid="base-fee-input"]', '8.5');
await driver.fill('[data-testid="base-fee-input"]', '8,5');

// enter priority fee
await driver.fill('[data-testid="priority-fee-input"]', '8.5');
await driver.fill('[data-testid="priority-fee-input"]', '8,5');

// save default values
await driver.clickElement('input[type="checkbox"]');
Expand Down Expand Up @@ -363,6 +363,11 @@ describe('Editing Confirm Transaction', function () {
text: '0.0008 ETH',
});

await driver.waitForSelector({
css: '[data-testid="native-currency"]',
text: '$1.44',
});

// confirms the transaction
await driver.clickElement({ text: 'Confirm', tag: 'button' });

Expand Down Expand Up @@ -430,6 +435,11 @@ describe('Editing Confirm Transaction', function () {
text: '0.0019',
});

await driver.waitForSelector({
css: '[data-testid="native-currency"]',
text: '$3.15',
});

// confirms the transaction
await driver.clickElement({ text: 'Confirm', tag: 'button' });

Expand Down
25 changes: 25 additions & 0 deletions test/e2e/tests/transaction/gas-estimates.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,11 @@ describe('Gas estimates generated by MetaMask', function () {
css: '[data-testid="first-gas-field"]',
text: '0.0004 ETH',
});

await driver.waitForSelector({
css: '[data-testid="native-currency"]',
text: '$0.75',
});
},
);
});
Expand Down Expand Up @@ -323,6 +328,10 @@ describe('Gas estimates generated by MetaMask', function () {
css: '[data-testid="first-gas-field"]',
text: '0 ETH',
});
await driver.waitForSelector({
css: '[data-testid="native-currency"]',
text: '$0.07',
});
},
);
});
Expand Down Expand Up @@ -362,6 +371,10 @@ describe('Gas estimates generated by MetaMask', function () {
css: '[data-testid="first-gas-field"]',
text: '0 ETH',
});
await driver.waitForSelector({
css: '[data-testid="native-currency"]',
text: '$0.07',
});
},
);
});
Expand Down Expand Up @@ -396,6 +409,10 @@ describe('Gas estimates generated by MetaMask', function () {
css: '[data-testid="first-gas-field"]',
text: '0 ETH',
});
await driver.waitForSelector({
css: '[data-testid="native-currency"]',
text: '$0.07',
});
},
);
});
Expand Down Expand Up @@ -442,6 +459,10 @@ describe('Gas estimates generated by MetaMask', function () {
css: '[data-testid="first-gas-field"]',
text: '0 ETH',
});
await driver.waitForSelector({
css: '[data-testid="native-currency"]',
text: '$0.07',
});
},
);
});
Expand Down Expand Up @@ -471,6 +492,10 @@ describe('Gas estimates generated by MetaMask', function () {
css: '[data-testid="first-gas-field"]',
text: '0 ETH',
});
await driver.waitForSelector({
css: '[data-testid="native-currency"]',
text: '$0.07',
});
},
);
});
Expand Down
5 changes: 3 additions & 2 deletions test/e2e/tests/transaction/navigate-transactions.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import Confirmation from '../../page-objects/pages/confirmations/redesign/confirmation';

const {
default: Confirmation,
} = require('../../page-objects/pages/confirmations/redesign/confirmation');
const {
createDappTransaction,
} = require('../../page-objects/flows/transaction');
Expand Down
Loading

0 comments on commit 2860219

Please sign in to comment.