Skip to content

Unexpected timeouts on events should fail the test immediately #1605

@Thalley

Description

@Thalley

The wait_for_event and wait_event_with_condition functions start a timer when waiting for an event. However if that event is never received, the tests just continue operating as nothing has happened. In some cases this still lead to passing tests, as some of the events that AutoPTS is waiting for, are not actually needed (except to implement verification on the AutoPTS side). In worst cases, the timeout triggers an "OK" or similar to a WID with user action, thus causing false positives, as we claim that we have received an event we may not have.

When the timer expires in the 2 above functions, the currently running test should fail immediately with information about what even timed out, and possible also dump the current list of received events.

It may be useful to also be able to provide an option to allow the event to timeout, which is useful for tests where we expect no event, e.g. "Verify that no event has been received" WIDs.

I fully expect that this change will expose a number of false positives in the test suites.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions