Skip to content

Conversation

@Gudahtt
Copy link
Member

@Gudahtt Gudahtt commented Aug 20, 2025

Explanation

Tests that used the @metamask/base-controller/next export were not working correctly until after a build was completed. They were using the built code rather than the source code. On CI the tests run without any build, so they would always fail.

This was resolved up updating the TSConfig and Jest config to map the next export to the correct source code.

This unblocks #6335 as well as other controller migrations to the upcoming BaseController version.

References

Relates to #5626

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated my changes to consumers by updating changelogs for packages I've changed, highlighting breaking changes as necessary
  • I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes

@Gudahtt Gudahtt force-pushed the fix-tests-that-use-base-controller-next-export branch from 7262b93 to a85fa14 Compare August 20, 2025 18:13
@Gudahtt Gudahtt marked this pull request as ready for review August 20, 2025 18:32
@Gudahtt Gudahtt force-pushed the fix-tests-that-use-base-controller-next-export branch from a85fa14 to 1ccaefd Compare August 20, 2025 18:32
Tests that used the `@metamask/base-controller/next` export were not
working correctly until after a build was completed. They were using
the built code rather than the source code. On CI the tests run without
any build, so they would always fail.

This was resolved up updating the TSConfig and Jest config to map the
`next` export to the correct source code.

This unblocks #6335 as well as other controller migrations to the
upcoming BaseController version.
@Gudahtt Gudahtt force-pushed the fix-tests-that-use-base-controller-next-export branch from 1ccaefd to fd4a4f8 Compare August 21, 2025 12:15
Copy link
Contributor

@cryptodev-2s cryptodev-2s left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@Gudahtt Gudahtt enabled auto-merge (squash) August 21, 2025 12:19
@Gudahtt Gudahtt merged commit 9640c95 into main Aug 21, 2025
231 checks passed
@Gudahtt Gudahtt deleted the fix-tests-that-use-base-controller-next-export branch August 21, 2025 12:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants