Skip to content

Add Scope.Clear and Scope.ClearBreadcrumbs methods - #2284

Merged
mattjohnsonpint merged 4 commits into
getsentry:mainfrom
jamescrosswell:feat/clear-scope
Apr 6, 2023
Merged

mattjohnsonpint merged 4 commits into
getsentry:mainfrom
jamescrosswell:feat/clear-scope

Conversation

@jamescrosswell

Copy link
Copy Markdown
Collaborator

Resolves #2272

Comment thread test/Sentry.Tests/ScopeTests.cs Resolved
@mattjohnsonpint

Copy link
Copy Markdown
Contributor

Thanks for the PR! I'll review soon and get back to you. 🙂

@mattjohnsonpint mattjohnsonpint left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks pretty good overall! A few things to address as indicated inline.

Also:

  • After you switch the methods public, re-run tests locally and you'll see the public API snapshots have been updated. Commit those. (You can use dotnet test test/Sentry.Tests --filter ApiApprovalTests if you want to do it fast. Or just run all tests.)
  • Add an entry to CHANGELOG.md, pointing back at this PR.

Thanks!

Comment thread src/Sentry/Scope.cs Resolved
Comment thread src/Sentry/Scope.cs Resolved
Comment thread src/Sentry/Scope.cs Resolved
Comment thread test/Sentry.Tests/ScopeTests.cs Resolved
Comment thread test/Sentry.Tests/ScopeTests.cs Resolved
Comment thread test/Sentry.Tests/ScopeTests.cs Resolved
- Provided summary documentation for the ClearBreadcrumbs method
- Committed updated verified.txt files for API approval tests
…e SentryScopeManager

- Added extension method to set fake values on a Scope during testing
- Added extension method to ensure Scopes are equivalent during testing
@mattjohnsonpint

Copy link
Copy Markdown
Contributor

Nice job. Thanks!!!

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.

Add Scope.Clear and Scope.ClearBreadcrumbs

2 participants