Skip to content

showAlertAsync defers Alert.alert invocation by a microtask, breaking synchronous expectations #45

Description

@imiziuk

Failing tests (5): All tests in AlarmScheduler.test.tsx › showAlertAsync.

What the tests assert: After calling showAlertAsync(...), Alert.alert should already have been invoked synchronously (so callers, including the next queued caller, observe a single visible alert on the same frame).

What actually happens: The first showAlertAsync call returns without ever invoking Alert.alert in the current tick. alertSpy.mock.calls[0] is undefined when the assertion runs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    Fields

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions