Skip to content

Conversation

@TylerHelmuth
Copy link
Member

Fixes #10927.

go test status_test.go --count 100 passed.

@TylerHelmuth TylerHelmuth added Skip Changelog PRs that do not require a CHANGELOG.md entry Skip Contrib Tests labels Aug 20, 2024
@TylerHelmuth TylerHelmuth requested review from a team and dmitryax August 20, 2024 17:48
@codecov
Copy link

codecov bot commented Aug 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.62%. Comparing base (2d6cb02) to head (c995fa3).
Report is 17 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #10929   +/-   ##
=======================================
  Coverage   91.62%   91.62%           
=======================================
  Files         406      406           
  Lines       19046    19046           
=======================================
  Hits        17450    17450           
  Misses       1237     1237           
  Partials      359      359           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

require.NoError(t, err)

assert.Equal(t, 5, len(eventsReceived))
require.Equal(t, 2, len(eventsReceived))
Copy link
Contributor

Choose a reason for hiding this comment

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

why is the value changed?

Copy link
Member Author

Choose a reason for hiding this comment

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

To simplify the test I added a check in the test extension's ComponentStatusChanged function to only record events for the component the test cares about. This changed the number or recorded sources from 5 to 2.

assert.Fail(t, "received too many events")
}
}
t.Logf("events received: %v", eventStr)
Copy link
Contributor

Choose a reason for hiding this comment

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

Just confirming that the two log statements were left intentionally

Copy link
Member Author

Choose a reason for hiding this comment

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

Ya I added these so that in the future, if a flaky test comes back, it will be a little easier to debug.

@codeboten codeboten merged commit a80ce1a into open-telemetry:main Aug 26, 2024
@github-actions github-actions bot added this to the next release milestone Aug 26, 2024
@TylerHelmuth TylerHelmuth deleted the fix-flaky-e2e-test branch August 27, 2024 00:45
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 Skip Contrib Tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Flaky test] Test_ComponentStatusReporting_SharedInstance flaky

2 participants