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

Move the Env testutil internal types into a single type #1234

Merged
merged 2 commits into from
Mar 1, 2024

Conversation

leighmcculloch
Copy link
Member

@leighmcculloch leighmcculloch commented Mar 1, 2024

What

Move the Env testutil internal types into a single type.

Why

The Env when used with testutils enabled has a few internal fields. Those internal fields are copied around between MaybeEnv and Env, and because they're individual fields there's repetitive calls on each field, and repetitive compiler attributes. It's painful each time we add a new one to remember and find all the places that need adding. Using a single type groups all those repetitive actions so we don't need to keep repeating them for new types to add.

I'm about to add another field.

@leighmcculloch leighmcculloch requested a review from dmkozh March 1, 2024 07:20
@leighmcculloch leighmcculloch marked this pull request as ready for review March 1, 2024 07:20
@leighmcculloch leighmcculloch added this pull request to the merge queue Mar 1, 2024
Merged via the queue into main with commit 9590be0 Mar 1, 2024
21 checks passed
@leighmcculloch leighmcculloch deleted the refactor-env-internal-testutils branch March 1, 2024 21:43
github-merge-queue bot pushed a commit that referenced this pull request Mar 1, 2024
### What
Add option to disable test snapshots on Env

### Why
In some situations a developer needs to disable test snapshots. The
default is that they are always on, in the interest of giving all
developers a way to identify unexpected and otherwise untested for
changed behavior during SDK upgrades, no protocol releases, or their own
developer lifecycle.

Close #1225

### Merging
This change is dependent on the following change merging first, and will
be kept in draft state until then:
- #1234
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.

Request: Disable test snapshot feature for individual tests
2 participants