FakeLogger class final

An in-memory LoggerContract for use in tests.

Captured messages are available in warnings, errors, traces, and infos so test assertions can inspect what was logged.

Implemented types

Constructors

FakeLogger()

Properties

errors List<String>
final
hashCode int
The hash code for this object.
no setterinherited
infos List<String>
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
traces List<Object>
final
warnings List<String>
final

Methods

error(String message) → void
override
fatal(Exception message) → void
override
info(String message) → void
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited
trace(Object message) → void
override
warn(String message) → void
override

Operators

operator ==(Object other) bool
The equality operator.
inherited