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

Rename base test assertion methods for consistency #2084

Merged
merged 4 commits into from
Aug 30, 2021

Conversation

owais
Copy link
Contributor

@owais owais commented Aug 30, 2021

Description

Update base test class to have more consistent assertion methods with rest of Python ecosystem.

  • Dev/Tooling enchancement
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

  • Existing Tests

Does This PR Require a Contrib Repo Change?

Checklist:

  • Followed the style guidelines of this project
  • Changelogs have been updated
  • Unit tests have been added
  • Documentation has been updated

@owais owais requested review from a team, aabmass and NathanielRN and removed request for a team August 30, 2021 17:42
@owais owais added the Skip Changelog PRs that do not require a CHANGELOG.md entry label Aug 30, 2021
@owais owais force-pushed the update-base-test branch 2 times, most recently from 6321479 to 3ed70c5 Compare August 30, 2021 18:15
@@ -44,11 +46,11 @@ def tearDownClass(cls):
def setUp(self):
self.memory_exporter.clear()

def check_span_instrumentation_info(self, span, module):
def assertSpanInstrumentationInfo(self, span, module):
Copy link
Contributor

Choose a reason for hiding this comment

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

Mentioned this in the contrib repo PR, but I would prefer the name assertSpanHasInstrumentationInfo

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated

@owais owais requested a review from codeboten August 30, 2021 19:16
@@ -44,11 +46,11 @@ def tearDownClass(cls):
def setUp(self):
self.memory_exporter.clear()

def check_span_instrumentation_info(self, span, module):
def assertSpanHasInstrumentationInfo(self, span, module):
Copy link
Contributor

Choose a reason for hiding this comment

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

Hm, not trying to be nitpicky but this name is misleading. It is not checking that the span has instrumentation info but that the span instrumentation info is the same as the one in the module.

Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe assertEqualSpanModuleInstrumentationInfo? 🤷

@owais owais requested a review from ocelotl August 30, 2021 20:22
@owais
Copy link
Contributor Author

owais commented Aug 30, 2021

I'm merging before other approvers want more renames. 😂

@owais owais merged commit b4ebef9 into open-telemetry:main Aug 30, 2021
@owais owais deleted the update-base-test branch August 30, 2021 20:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Skip Changelog PRs that do not require a CHANGELOG.md entry
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants