refactor(tests): convert the higher risk slice-to-map table tests#324
Merged
refactor(tests): convert the higher risk slice-to-map table tests#324
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
mwbrooks
commented
Jan 31, 2026
Comment on lines
+461
to
+462
| `Standalone workspace, AAA is requested \ | ||
| (workspace ID passed into apps.approvals.requests.create)`: { |
Member
Author
There was a problem hiding this comment.
note: This naming convention is a little strange, but I decided to keep it 1-to-1 with current implementation.
| if len(deployedApps) == 0 { | ||
| require.ErrorIs(t, err, os.ErrNotExist, "apps.json was not deleted") | ||
| } else { | ||
| for name, tc := range tests { |
Member
Author
There was a problem hiding this comment.
note: This ---/+++ looks scary, but it's just fixing this test by wrapping each iteration in a t.Run function.
Base automatically changed from
mwbrooks-table-test-consistent-p6-medium-high-risk
to
main
February 4, 2026 23:32
Member
Author
|
Thanks a bunch and appreciate the reviews! They're dry reads but now we have some consistent test formats to use going forward! 🙇🏻 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Related to #315, #316, #320, #321, #322, #323
This pull request refactors the remaining higher risk Table Tests from the Slice-to-Map Pattern. It's focused on tests with OS mocks, HTTP mocks, and nested logic.
Reviewers
This is the last one! Congrats, you've reached the end of the Slice-to-Map Conversion Book 📚
Requirements