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

Add test context that assert an exception was not raised #1891

Closed
ocelotl opened this issue Jun 3, 2021 · 0 comments · Fixed by #3630
Closed

Add test context that assert an exception was not raised #1891

ocelotl opened this issue Jun 3, 2021 · 0 comments · Fixed by #3630
Assignees

Comments

@ocelotl
Copy link
Contributor

ocelotl commented Jun 3, 2021

Sometimes we need to assert that an exception was not raised. This is doable but it requires a try/except block and a call to self.fail that can be very repetitive when this is being asserted many times in the same test suite. Find a solution for this.

ocelotl added a commit to ocelotl/opentelemetry-python that referenced this issue Jun 3, 2021
ocelotl added a commit to ocelotl/opentelemetry-python that referenced this issue Jun 3, 2021
ocelotl added a commit to ocelotl/opentelemetry-python that referenced this issue Jun 10, 2021
ocelotl added a commit to ocelotl/opentelemetry-python that referenced this issue Jan 11, 2024
ocelotl added a commit to ocelotl/opentelemetry-python that referenced this issue Jan 12, 2024
ocelotl added a commit to ocelotl/opentelemetry-python that referenced this issue Jan 25, 2024
ocelotl added a commit that referenced this issue Jan 25, 2024
* Add test context for no exception raised

Fixes #1891

* Add missing test class
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant