expector library

A library to write tests in a fluent manner and more easily.

test('my test', () {
  expectThat(value).isNotEmpty;
});

Classes

Expector<T>
The base object containing the value to be checked.

Extensions

BoolExpector on Expector<bool>
Expectations for bool.
DoubleExpector on Expector<double>
Expectations for double.
FunctionExpector on Expector<Function>
Expectations for Function.
FutureExpector on Expector<Future>
Expectations for Future.
IntExpector on Expector<int>
Expectations for int.
IterableExpector on Expector<Iterable<T>>
Expectations for Iterable.
ListExpector on Expector<List<T>>
Expectations for List.
MapExpector on Expector<Map<K, V>>
Expectations for Map.
NonNullableObjectExpector on Expector<T>
Expectations for non nullable objects.
NullableExpector on Expector<T?>
Expectations for objects that can be null.
NumExpector on Expector<T>
Expectations for num.
ObjectExpector on Expector<T>
Expectations for nullable objects.
SetExpector on Expector<Set<T>>
Expectations for Set.
StringExpector on Expector<String>
Expectations for String.

Functions

expectThat<T>(T t) Expector<T>
Start an expectation about t.