Skip to content

Unstable Test TimerTest #5937

@ahus1

Description

@ahus1

Version

5.0

Context

When running job https://github.com/eclipse-vertx/vert.x/actions/runs/21745456833/job/62730103189 the following test failed:

Error:  Failures: 
Error:    TimerTest.access$600:33->AsyncTestBase.assertTrue:378

Steps to reproduce

This is a random failure in CI.

Looking at the code, it relies on a monotonic clock, wich might have not worked in that execution on a Windows system.

assertTrue( System.currentTimeMillis() - now >= delay.initialDelay + count * delay.delay);

It would be more reliable to use System.nanoTime() which is guaranteed to be monotonic as a first attempt.

Do you have a reproducer?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions