Skip to content

Conversation

OliverO2
Copy link
Contributor

@OliverO2 OliverO2 commented Jun 21, 2024

Fix tests:

  • Make ContinuallySpec tolerate test duration >= 1s
  • Make EventuallySpec use virtual time

@OliverO2 OliverO2 mentioned this pull request Jun 21, 2024
20 tasks
@OliverO2 OliverO2 requested a review from aSemy June 21, 2024 23:54
@aSemy aSemy added this pull request to the merge queue Jun 22, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 22, 2024
@aSemy aSemy added this pull request to the merge queue Jun 22, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 22, 2024
@aSemy
Copy link
Contributor

aSemy commented Jun 22, 2024

Looks like the merge queue is failing with an unrelated flakey error (caused by ##4119?), so I'll go ahead and directly merge.

com.sksamuel.kotest.runner.junit5.DiscoveryTestWithSelectors[jvm]
  Test discovery should support multiple package selectors[jvm] FAILED (6.9s)
  io.kotest.engine.config.ConfigurationException: io.kotest.engine.config.ConfigurationException: io.github.classgraph.ClassGraphException: Uncaught exception during scan
  Caused by: io.kotest.engine.config.ConfigurationException: io.github.classgraph.ClassGraphException: Uncaught exception during scan
  Caused by: io.github.classgraph.ClassGraphException: Uncaught exception during scan
  Caused by: java.lang.OutOfMemoryError: Java heap space

I created a follow-up to improve Kotest classpath scanning #4144

@aSemy aSemy merged commit f1c11fc into master Jun 22, 2024
@aSemy aSemy deleted the oo2/fix-more-flaky-tests branch June 22, 2024 08:27
@aSemy
Copy link
Contributor

aSemy commented Jun 22, 2024

  • Make EventuallySpec use virtual time

I've already merged so this question is too late, but I don't think this PR enables virtual time for eventually?

I see the PR sets coroutineTestScope = true, but it doesn't set a time source like in the other eventually test:

): TestEventuallyResult<T> = withContext(EventuallyTimeSource(testCoroutineScheduler.timeSource)) {

@OliverO2
Copy link
Contributor Author

I'm preparing a PR to address the issue, so that the time source used in tests is always synchronized with the scheduler in use.

@OliverO2
Copy link
Contributor Author

OK, got that little thing here: #4149

@mirageoasis mirageoasis mentioned this pull request Jul 2, 2024
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