1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Fix proptype errors in network dropdown, tx list item details, and account details modal tests (#14747)

This commit is contained in:
Thomas Huang 2022-05-31 09:46:38 -07:00 committed by GitHub
parent 8961ea5d1b
commit db6998c66a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 16 additions and 6 deletions

View File

@ -19,6 +19,7 @@ describe('Network Dropdown', () => {
provider: {
type: 'test',
},
showTestnetMessageInDropdown: false,
preferences: {
showTestNetworks: true,
},
@ -50,6 +51,7 @@ describe('Network Dropdown', () => {
provider: {
type: 'test',
},
showTestnetMessageInDropdown: false,
preferences: {
showTestNetworks: true,
},
@ -156,6 +158,7 @@ describe('Network Dropdown', () => {
provider: {
type: 'test',
},
showTestnetMessageInDropdown: false,
preferences: {
showTestNetworks: false,
},

View File

@ -30,12 +30,14 @@ describe('Account Details Modal', () => {
name: 'Account 1',
},
},
accounts: {
address: '0xAddress',
lastSelected: 1637764711510,
name: 'Account 1',
balance: '0x543a5fb6caccf599',
},
accounts: [
{
address: '0xAddress',
lastSelected: 1637764711510,
name: 'Account 1',
balance: '0x543a5fb6caccf599',
},
],
};
beforeEach(() => {

View File

@ -6,6 +6,7 @@ import TransactionBreakdown from '../transaction-breakdown';
import TransactionActivityLog from '../transaction-activity-log';
import { TRANSACTION_STATUSES } from '../../../../shared/constants/transaction';
import { GAS_LIMITS } from '../../../../shared/constants/gas';
import TransactionStatus from '../transaction-status/transaction-status.component';
import TransactionListItemDetails from './transaction-list-item-details.component';
describe('TransactionListItemDetails Component', () => {
@ -40,6 +41,7 @@ describe('TransactionListItemDetails Component', () => {
transactionGroup={transactionGroup}
senderNickname="sender-nickname"
recipientNickname="recipient-nickname"
transactionStatus={TransactionStatus}
/>,
{ context: { t: (str1, str2) => (str2 ? str1 + str2 : str1) } },
);
@ -86,6 +88,7 @@ describe('TransactionListItemDetails Component', () => {
showSpeedUp
senderNickname="sender-nickname"
recipientNickname="recipient-nickname"
transactionStatus={TransactionStatus}
/>,
{ context: { t: (str1, str2) => (str2 ? str1 + str2 : str1) } },
);
@ -127,6 +130,7 @@ describe('TransactionListItemDetails Component', () => {
transactionGroup={transactionGroup}
senderNickname="sender-nickname"
recipientNickname="recipient-nickname"
transactionStatus={TransactionStatus}
/>,
{ context: { t: (str1, str2) => (str2 ? str1 + str2 : str1) } },
);
@ -171,6 +175,7 @@ describe('TransactionListItemDetails Component', () => {
transactionGroup={transactionGroup}
senderNickname="sender-nickname"
recipientNickname="recipient-nickname"
transactionStatus={TransactionStatus}
/>,
{ context: { t: (str1, str2) => (str2 ? str1 + str2 : str1) } },
);