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

Update span tests #586

Merged
merged 2 commits into from
Feb 2, 2022
Merged

Update span tests #586

merged 2 commits into from
Feb 2, 2022

Conversation

tombruijn
Copy link
Member

This is a small extraction of an attempt at a larger refactor to try something out for #556
[skip changeset]

Remove duplicate test for trace_id

This test asserts if the internal object's trace_id is set. This is
tested in the "exposes a traceId" test already.

The description of what the test says it does is covered under the
"creates a Root/ChildSpan with a timestamp" test.

Add unit tests for setCategory

The span tests didn't have a case for the setCategory helper.

I've reused the setName test for the ChildSpan. It's possible to set
a "name" on a ChildSpan, but the value is ignored. It's not relevant to
test this scenario.

This test asserts if the internal object's `trace_id` is set. This is
tested in the "exposes a traceId" test already.

The description of what the test says it does is covered under the
"creates a Root/ChildSpan with a timestamp" test.
The span tests didn't have a case for the `setCategory` helper.

I've reused the `setName` test for the `ChildSpan`. It's possible to set
a "name" on a ChildSpan, but the value is ignored. It's not relevant to
test this scenario.
@tombruijn tombruijn merged commit 9baec12 into main Feb 2, 2022
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.

3 participants