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

Remove backtrace cleaner filter after test #1303

Merged
merged 1 commit into from
Sep 25, 2024
Merged

Conversation

tombruijn
Copy link
Member

I ran into an issue adding a spec with the line number "123". It would be replaced with "1?3" whenever Rails was loaded. That's because this spec left the filters in the cleaner's config.

Disable the filter after the spec has completed. I could go into the backtrace cleaner internals and remove the lambda from the @filters instance variable, but this solution with our global store that's only set to true for this spec is fine. The store is cleared after every spec.

[skip changeset]
[skip review]

I ran into an issue adding a spec with the line number "123". It would
be replaced with "1?3" whenever Rails was loaded. That's because this
spec left the filters in the cleaner's config.

Disable the filter after the spec has completed. I could go into the
backtrace cleaner internals and remove the lambda from the `@filters`
instance variable, but this solution with our global store that's only
set to true for this spec is fine. The store is cleared after every
spec.

[skip changeset]
@tombruijn tombruijn self-assigned this Sep 25, 2024
@tombruijn tombruijn merged commit 67f958e into main Sep 25, 2024
122 checks passed
@tombruijn tombruijn deleted the fix-transacton-spec-state branch September 25, 2024 09:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant