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

Better Assert (with error message) for timestamp range #168

Merged

Conversation

lmolkova
Copy link

GoSpanData_EndedSpan test became flaky after timestamp changes, this PR only improves assert to generate error message and does nothing to fix the test

Expected: True
Actual: False

Stack trace
   at OpenTelemetry.Trace.Test.SpanTest.AssertApproxSameTimestamp(DateTime one, DateTime two) in D:\a\1\s\test\OpenTelemetry.Tests\Impl\Trace\SpanTest.cs:line 703
   at OpenTelemetry.Trace.Test.SpanTest.<GoSpanData_EndedSpan>d__11.MoveNext() in D:\a\1\s\test\OpenTelemetry.Tests\Impl\Trace\SpanTest.cs:line 303
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

https://dev.azure.com/opentelemetry/pipelines/_test/analytics?definitionId=1&contextType=build

@lmolkova lmolkova merged commit ff8f7b6 into open-telemetry:master Aug 7, 2019
@lmolkova lmolkova deleted the betterErrorMessageForFlackyTest branch December 19, 2019 05:35
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.

2 participants