mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-22 09:57:02 +01:00
addresses an issue found in 10.6.0 QA (#12710)
* addresses an issue found in 10.6.0 QA Signed-off-by: Akintayo A. Olusegun <akintayo.segun@gmail.com> * update test cases. Signed-off-by: Akintayo A. Olusegun <akintayo.segun@gmail.com> * Fixes unit test texts to pass Signed-off-by: Akintayo A. Olusegun <akintayo.segun@gmail.com>
This commit is contained in:
parent
c84604b5e4
commit
0cf7455e18
@ -193,7 +193,7 @@
|
|||||||
"message": "Approved"
|
"message": "Approved"
|
||||||
},
|
},
|
||||||
"approvedAmountWithColon": {
|
"approvedAmountWithColon": {
|
||||||
"message": "Approved Amount:"
|
"message": "Approved amount:"
|
||||||
},
|
},
|
||||||
"asset": {
|
"asset": {
|
||||||
"message": "Asset"
|
"message": "Asset"
|
||||||
@ -1088,7 +1088,7 @@
|
|||||||
"message": "Goerli Test Network"
|
"message": "Goerli Test Network"
|
||||||
},
|
},
|
||||||
"grantedToWithColon": {
|
"grantedToWithColon": {
|
||||||
"message": "Granted To:"
|
"message": "Granted to:"
|
||||||
},
|
},
|
||||||
"happyToSeeYou": {
|
"happyToSeeYou": {
|
||||||
"message": "We’re happy to see you."
|
"message": "We’re happy to see you."
|
||||||
@ -1867,7 +1867,7 @@
|
|||||||
"message": "You have approved this permission"
|
"message": "You have approved this permission"
|
||||||
},
|
},
|
||||||
"permissionRequest": {
|
"permissionRequest": {
|
||||||
"message": "Permission Request"
|
"message": "Permission request"
|
||||||
},
|
},
|
||||||
"permissionUncheckedIconDescription": {
|
"permissionUncheckedIconDescription": {
|
||||||
"message": "You have not approved this permission"
|
"message": "You have not approved this permission"
|
||||||
@ -2887,7 +2887,7 @@
|
|||||||
"message": "Transaction encountered an error."
|
"message": "Transaction encountered an error."
|
||||||
},
|
},
|
||||||
"transactionFee": {
|
"transactionFee": {
|
||||||
"message": "Transaction Fee"
|
"message": "Transaction fee"
|
||||||
},
|
},
|
||||||
"transactionHistoryBaseFee": {
|
"transactionHistoryBaseFee": {
|
||||||
"message": "Base Fee (GWEI)"
|
"message": "Base Fee (GWEI)"
|
||||||
|
@ -58,7 +58,7 @@ describe('ConfirmApproveContent Component', () => {
|
|||||||
|
|
||||||
const editButtons = getAllByText('Edit');
|
const editButtons = getAllByText('Edit');
|
||||||
|
|
||||||
expect(queryByText('Transaction Fee')).toBeInTheDocument();
|
expect(queryByText('Transaction fee')).toBeInTheDocument();
|
||||||
expect(
|
expect(
|
||||||
queryByText('A fee is associated with this request.'),
|
queryByText('A fee is associated with this request.'),
|
||||||
).toBeInTheDocument();
|
).toBeInTheDocument();
|
||||||
@ -72,13 +72,13 @@ describe('ConfirmApproveContent Component', () => {
|
|||||||
expect(props.showCustomizeNonceModal).toHaveBeenCalledTimes(1);
|
expect(props.showCustomizeNonceModal).toHaveBeenCalledTimes(1);
|
||||||
|
|
||||||
const showHideTxDetails = getByText('View full transaction details');
|
const showHideTxDetails = getByText('View full transaction details');
|
||||||
expect(queryByText('Permission Request')).not.toBeInTheDocument();
|
expect(queryByText('Permission request')).not.toBeInTheDocument();
|
||||||
expect(queryByText('Approved Amount:')).not.toBeInTheDocument();
|
expect(queryByText('Approved amount:')).not.toBeInTheDocument();
|
||||||
expect(queryByText('Granted To:')).not.toBeInTheDocument();
|
expect(queryByText('Granted to:')).not.toBeInTheDocument();
|
||||||
fireEvent.click(showHideTxDetails);
|
fireEvent.click(showHideTxDetails);
|
||||||
expect(getByText('Permission Request')).toBeInTheDocument();
|
expect(getByText('Permission request')).toBeInTheDocument();
|
||||||
expect(getByText('Approved Amount:')).toBeInTheDocument();
|
expect(getByText('Approved amount:')).toBeInTheDocument();
|
||||||
expect(getByText('Granted To:')).toBeInTheDocument();
|
expect(getByText('Granted to:')).toBeInTheDocument();
|
||||||
expect(getByText('0x9bc5...fef4')).toBeInTheDocument();
|
expect(getByText('0x9bc5...fef4')).toBeInTheDocument();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -144,9 +144,7 @@ export default function ConfirmApprove() {
|
|||||||
}, [checkIfContract]);
|
}, [checkIfContract]);
|
||||||
|
|
||||||
const { origin } = transaction;
|
const { origin } = transaction;
|
||||||
const formattedOrigin = origin
|
const formattedOrigin = origin || '';
|
||||||
? origin[0].toUpperCase() + origin.slice(1)
|
|
||||||
: '';
|
|
||||||
|
|
||||||
const { icon: siteImage = '' } = domainMetadata[origin] || {};
|
const { icon: siteImage = '' } = domainMetadata[origin] || {};
|
||||||
|
|
||||||
|
@ -107,7 +107,7 @@ exports[`GasCustomizationModalComponent renders the component with initial props
|
|||||||
<span
|
<span
|
||||||
class="gas-modal-content__info-row__transaction-info__label"
|
class="gas-modal-content__info-row__transaction-info__label"
|
||||||
>
|
>
|
||||||
Transaction Fee
|
Transaction fee
|
||||||
</span>
|
</span>
|
||||||
<span
|
<span
|
||||||
class="gas-modal-content__info-row__transaction-info__value"
|
class="gas-modal-content__info-row__transaction-info__value"
|
||||||
|
@ -69,7 +69,7 @@ exports[`GasCustomizationModalContainer renders the component with initial props
|
|||||||
<span
|
<span
|
||||||
class="gas-modal-content__info-row__transaction-info__label"
|
class="gas-modal-content__info-row__transaction-info__label"
|
||||||
>
|
>
|
||||||
Transaction Fee
|
Transaction fee
|
||||||
</span>
|
</span>
|
||||||
<span
|
<span
|
||||||
class="gas-modal-content__info-row__transaction-info__value"
|
class="gas-modal-content__info-row__transaction-info__value"
|
||||||
|
@ -19,7 +19,7 @@ describe('GasCustomizationModalContainer', () => {
|
|||||||
expect(getByText('Advanced')).toBeInTheDocument();
|
expect(getByText('Advanced')).toBeInTheDocument();
|
||||||
expect(getByText('Estimated Processing Times')).toBeInTheDocument();
|
expect(getByText('Estimated Processing Times')).toBeInTheDocument();
|
||||||
expect(getByText('Send Amount')).toBeInTheDocument();
|
expect(getByText('Send Amount')).toBeInTheDocument();
|
||||||
expect(getByText('Transaction Fee')).toBeInTheDocument();
|
expect(getByText('Transaction fee')).toBeInTheDocument();
|
||||||
expect(
|
expect(
|
||||||
getByTestId('gas-modal-content__info-row__send-info'),
|
getByTestId('gas-modal-content__info-row__send-info'),
|
||||||
).toMatchSnapshot();
|
).toMatchSnapshot();
|
||||||
|
Loading…
Reference in New Issue
Block a user