fake_async 1.1.0 copy "fake_async: ^1.1.0" to clipboard
fake_async: ^1.1.0 copied to clipboard

outdated

Fake asynchronous events such as timers and microtasks for deterministic testing.

1.1.0 #

  • Exposed the FakeTimer class as a public class.
  • Added FakeAsync.pendingTimers which gives access to all pending timers at the time of the call.

1.0.2 #

  • Update min SDK to 2.2.0

1.0.1 #

  • Update to lowercase Dart core library constants.
  • Fix use of deprecated isInstanceOf matcher.

1.0.0 #

This release contains the FakeAsync class that was defined in quiver. It's backwards-compatible with both the quiver version and the old version of the fake_async package.

New Features #

  • A top-level fakeAsync() function was added that encapsulates new FakeAsync().run(...).

New Features Relative to quiver #

  • FakeAsync.elapsed returns the total amount of fake time elapsed since the FakeAsync instance was created.

  • new FakeAsync() now takes an initialTime argument that sets the default time for clocks created with FakeAsync.getClock(), and for the clock package's top-level clock variable.

New Features Relative to fake_async 0.1 #

  • FakeAsync.periodicTimerCount, FakeAsync.nonPeriodicTimerCount, and FakeAsync.microtaskCount provide visibility into the events scheduled within FakeAsync.run().

  • FakeAsync.getClock() provides access to fully-featured Clock objects based on FakeAsync's elapsed time.

  • FakeAsync.flushMicrotasks() empties the microtask queue without elapsing any time or running any timers.

  • FakeAsync.flushTimers() runs all microtasks and timers until there are no more scheduled.

0.1.2 #

  • Integrate with the clock package.
107
likes
0
pub points
99%
popularity

Publisher

verified publisherdart.dev

Fake asynchronous events such as timers and microtasks for deterministic testing.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

clock, collection

More

Packages that depend on fake_async