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

830 reduce flakiness of some tests #846

Merged
merged 9 commits into from
Jan 6, 2025

Conversation

MGaetan89
Copy link
Member

Pull request

Description

This PR attempts to mitigate flakiness of some tests.

  • For the TimeoutException mentioned in Reduce flakiness of some tests #830, I expect that they will be fixed with Investigate local file for tests #831.
  • For the MockKException, the issue probably comes from an other test than CommandersActTrackerIntegrationTest, because CommandersActTrackerIntegrationTest doesn't use a mocked player.
  • For the AssertionError, I'll continue the investigation and try to submit a fix in a dedicated PR.

Changes made

  • Add some missing clearAllMocks() calls.
  • Create a SRG PillarboxExoPlayer configured for tests.
  • Continue migration from jUnit to Kotlin Test where possible.
  • Make TestPillarboxRunHelper.runUntilEvents() support multiple events.
  • Avoid sending networks requests:
    • Monitoring has been disabled in tests.
    • RequestSenderTest now uses a mocked OkHttpClient instead of using HttpBin.

Checklist

  • APIs have been properly documented (if relevant).
  • The documentation has been updated (if relevant).
  • New unit tests have been written (if relevant).
  • The demo has been updated (if relevant).

Copy link

github-actions bot commented Jan 3, 2025

Code Coverage

Overall Project 52.02% 🟢

There is no coverage information present for the Files changed

@MGaetan89 MGaetan89 linked an issue Jan 5, 2025 that may be closed by this pull request
Base automatically changed from fix_media_url to main January 6, 2025 08:22
Copy link
Contributor

@StaehliJ StaehliJ left a comment

Choose a reason for hiding this comment

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

Sounds good, will see if we have less flaky tests

@StaehliJ StaehliJ added this pull request to the merge queue Jan 6, 2025
Merged via the queue into main with commit 4615146 Jan 6, 2025
9 checks passed
@StaehliJ StaehliJ deleted the 830-reduce-flakiness-of-some-tests branch January 6, 2025 08:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: ✅ Done
Development

Successfully merging this pull request may close these issues.

Reduce flakiness of some tests
2 participants