open-telemetry / opentelemetry-python

OpenTelemetry Python API and SDK
https://opentelemetry.io
Apache License 2.0
1.66k stars 568 forks source link

Make opentelemetry-test-utils tests more robust to error format #3961

Closed musicinmybrain closed 3 weeks ago

musicinmybrain commented 3 weeks ago

Description

Adapts opentelemetry-test-utils for Python 3.13 improved error messages by making TestAssertNotRaises.test_missing_exception insensitive to the exact line numbers of expected text within the error message.

Fixes #3953.

Type of change

Please delete options that are not relevant.

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

$ tox -e py313-opentelemetry-test-utils
$ tox -e py312-opentelemetry-test-utils

Does This PR Require a Contrib Repo Change?

Checklist: