Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Hide redesigned contract interaction confirmation #27346

Closed

Conversation

pedronfigueiredo
Copy link
Contributor

@pedronfigueiredo pedronfigueiredo commented Sep 23, 2024

Description

Hides redesigned contract interaction confirmation for this release.

Even if the user opts into the redesigned confirmations through the experimental settings, s/he will not see any redesigned transaction confirmations.

Some tests in useConfirmationAlertMetrics and one from useConfirmationAlertMetrics were removed because the metrics event is only sent for enabled redesign transaction types which is now empty

  const isValidType = REDESIGN_TRANSACTION_TYPES.includes(
    currentConfirmation?.type as TransactionType,
  );

Tests for transactions in useCurrentConfirmation similarly expected contract interaction as a transaction type since it was the first implemented.

Tests for useSigningOrSubmittingAlerts and usePendingTransactionAlertssimilarly usedisValidType` shown above to determine wether or not to show the alert, so a few test cases had to be amended.

One snapshot for the header component had to be updated because the advanced details toggle button is only shown for redesigned transaction types.

One integration test for the contract interaction type was skipped.

Eight e2e tests for this transaction type, one for metrics and one related to snaps functionality for this transaction type were skipped.

Open in GitHub Codespaces

Related issues

Fixes:

Manual testing steps

  1. Enable redesigned transaction screens in the experimental settings page
  2. Create a contract interaction transaction via the mint erc721 button in the test dapp
  3. The old confirmation screen should appear.

Screenshots/Recordings

Before

After

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

@pedronfigueiredo pedronfigueiredo added the team-confirmations Push issues to confirmations team label Sep 23, 2024
@pedronfigueiredo pedronfigueiredo self-assigned this Sep 23, 2024
@pedronfigueiredo pedronfigueiredo requested a review from a team as a code owner September 23, 2024 15:39
Copy link
Contributor

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

jpuri
jpuri previously approved these changes Sep 23, 2024
Copy link

codecov bot commented Sep 24, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 70.07%. Comparing base (439f7d6) to head (cdc96be).
Report is 20 commits behind head on Version-v12.3.0.

Additional details and impacted files
@@                 Coverage Diff                 @@
##           Version-v12.3.0   #27346      +/-   ##
===================================================
- Coverage            70.24%   70.07%   -0.17%     
===================================================
  Files                 1426     1432       +6     
  Lines                50239    50428     +189     
  Branches             13954    13990      +36     
===================================================
+ Hits                 35289    35335      +46     
- Misses               14950    15093     +143     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@metamaskbot
Copy link
Collaborator

Builds ready [cdc96be]
Page Load Metrics (1854 ± 60 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint23621801773373179
domContentLoaded16552125180811957
load17072194185412460
domInteractive12105432010

@pedronfigueiredo
Copy link
Contributor Author

This was a back up plan for the release, not needed anymore

@github-actions github-actions bot locked and limited conversation to collaborators Sep 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
team-confirmations Push issues to confirmations team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants