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

refactor: split migrations into multiple files #7873

Merged
merged 10 commits into from
Dec 4, 2023
Merged

Conversation

dbrans
Copy link
Contributor

@dbrans dbrans commented Nov 18, 2023

Description

Split each migration function and the associated unit tests into separate files.

See the extension approach which also exports the migration version from each individual migration file (example)

Related issues

Fixes: #7845

Manual testing steps

Screenshots/Recordings

Before

After

Pre-merge author checklist

  • Run e2e test as smoke test
  • Ensure test for migration 25 is unaffected
  • I’ve followed MetaMask Coding Standards.
  • I've clearly explained what problem this PR is solving and how it is solved.
  • I've linked related issues
  • I've included manual testing steps
  • I've included screenshots/recordings if applicable
  • I’ve included tests if applicable
  • I’ve documented my code using JSDoc format if applicable
  • I’ve applied the right labels on the PR (see labeling guidelines). Not required for external contributors.
  • I’ve properly set the pull request status:
    • In case it's not yet "ready for review", I've set it to "draft".
    • In case it's "ready for review", I've changed it from "draft" to "non-draft".

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.

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.

@codecov-commenter
Copy link

codecov-commenter commented Nov 18, 2023

Codecov Report

Attention: 151 lines in your changes are missing coverage. Please review.

Comparison is base (199aa40) 36.60% compared to head (3b2eaed) 36.60%.
Report is 2 commits behind head on main.

Files Patch % Lines
app/store/migrations/004.js 0.00% 30 Missing ⚠️
app/store/migrations/007.js 0.00% 18 Missing ⚠️
app/store/migrations/008.js 0.00% 17 Missing ⚠️
app/store/migrations/003.js 0.00% 11 Missing ⚠️
app/store/migrations/013.js 0.00% 11 Missing ⚠️
app/store/migrations/001.js 0.00% 8 Missing ⚠️
app/store/migrations/012.js 0.00% 8 Missing ⚠️
app/store/migrations/000.js 0.00% 7 Missing ⚠️
app/store/migrations/002.js 0.00% 7 Missing ⚠️
app/store/migrations/005.js 0.00% 4 Missing ⚠️
... and 10 more
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #7873   +/-   ##
=======================================
  Coverage   36.60%   36.60%           
=======================================
  Files        1092     1120   +28     
  Lines       29178    29178           
  Branches     2677     2678    +1     
=======================================
  Hits        10681    10681           
  Misses      17885    17885           
  Partials      612      612           

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

@dbrans dbrans added No QA Needed/E2E Only Apply this label when your PR does not need any QA effort. team-confirmations-system DEPRECATED: please use "team-confirmations" label instead labels Nov 20, 2023
@dbrans dbrans marked this pull request as ready for review November 20, 2023 16:11
@dbrans dbrans requested a review from a team as a code owner November 20, 2023 16:11
Copy link
Contributor

E2E test started on Bitrise: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/07d34fed-5d1b-44ed-b8e4-a3267d112211
You can also kick off another Bitrise E2E smoke test by removing and re-applying the (Run Smoke E2E) label

@dbrans dbrans changed the title Chore: split migrations into multiple files refactor: split migrations into multiple files Nov 20, 2023
matthewwalsh0
matthewwalsh0 previously approved these changes Nov 28, 2023
matthewwalsh0
matthewwalsh0 previously approved these changes Dec 1, 2023
Copy link
Contributor

github-actions bot commented Dec 1, 2023

E2E test started on Bitrise: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/8bde408d-69af-453e-8898-2d9e03dd3cdf
You can also kick off another Bitrise E2E smoke test by removing and re-applying the (Run Smoke E2E) label

Copy link

sonarcloud bot commented Dec 1, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 9 Code Smells

47.8% 47.8% Coverage
0.0% 0.0% Duplication

@dbrans dbrans merged commit 459b487 into main Dec 4, 2023
26 checks passed
@dbrans dbrans deleted the chore/split-migrations branch December 4, 2023 13:54
@github-actions github-actions bot locked and limited conversation to collaborators Dec 4, 2023
@metamaskbot metamaskbot added the release-7.14.0 Issue or pull request that will be included in release 7.14.0 label Dec 4, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
No QA Needed/E2E Only Apply this label when your PR does not need any QA effort. release-7.14.0 Issue or pull request that will be included in release 7.14.0 team-confirmations-system DEPRECATED: please use "team-confirmations" label instead
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Split mobile migrations into separate files
6 participants