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

chore: Remove shared mocks package. #601

Merged
merged 6 commits into from
Oct 1, 2024
Merged

Conversation

kinyoklion
Copy link
Member

@kinyoklion kinyoklion commented Sep 30, 2024

The dependencies between the mocks, and the unpublished nature of the package, made maintenance complex. Additionally the mocks themselves cause the tests to be harder to maintain and understand.

This PR changes all test dependencies to be in their own project. If we need shared test code, then we could make shared code and not a package.

The main motivator for removal is the circular dependency relationship between the mocks and common. Updating common to support ESM is made more difficult, but needs to be done.

Overall this makes things much simpler at the cost of a couple hundred lines of total duplication. (As indicated by the PR additions versus subtractions.) There was code that was shared that was actually only used in singular test locations.

Fixes SDK-729.

@kinyoklion kinyoklion marked this pull request as ready for review October 1, 2024 17:18
@kinyoklion kinyoklion requested a review from a team as a code owner October 1, 2024 17:18
"exclude": [
"src/**/*.test.ts"
]
"include": ["LICENSE", "README.md", "package.json", "jsr.json", "src/**/*.ts"],
Copy link
Member Author

Choose a reason for hiding this comment

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

Unrelated lint change.

@kinyoklion kinyoklion merged commit 9ad25bd into main Oct 1, 2024
23 checks passed
@kinyoklion kinyoklion deleted the rlamb/no-more-shared-mocks branch October 1, 2024 20:12
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.

2 participants