leak_tracker_flutter_testing library

Classes

IgnoredLeaks
The total set of ignored leaks for both notGCed and notDisposed leaks.
LeakReport
Leak information, passed from application to DevTools and than extended by DevTools after deeper analysis.
Leaks
Detailed information about found leaks.
LeakTesting
Leak tracker settings for tests.
LeakTracking
Provides leak tracking functionality.
LeakTrackingTestConfig
Configuration for leak tracking to pass to an individual unit test.

Constants

isLeakFree → const Matcher
Checks if the leak collection is empty.

Properties

areCreateAndDispose Matcher
Checks if Iterable contains two events, first ObjectCreated and then ObjectDisposed.
getter/setter pair

Functions

maybeSetupLeakTrackingForTest(LeakTesting? settings, String testDescription) → void
Makes sure leak tracking is set up for a test.
maybeTearDownLeakTrackingForAll() Future<void>
Should be invoked after execution of all tests to report found leaks.
maybeTearDownLeakTrackingForTest() → void
If leak tracking is enabled, stops it and declares notDisposed objects as leaks.
memoryEvents(FutureOr<void> callback(), Type type) Future<List<ObjectEvent>>
Invokes callback and collects events dispatched to MemoryAllocations.instance for type.

Enums

LeakType