Detester is a low-ceremony unit testing framework. It is designed to work with matchers from the Darmatch library. Currently, it only runs on the standalone Dart VM. It also doesn't support testing asynchronous code.

First unit test

You write tests as top-level functions. Their names, by convention, start with test or should. Then you define a top-level function called suite.

import 'package:darmatch/matchers.dart';
import 'package:detester/detester.dart';
part 'package:detester/test.dart';

suite() => [

testArithmetics() {
  expectThat(1 + 1, equals(2));
  expectThat(2 + 2, equals(4));
  expectThat(4 + 4, equals(8));

This is complete Dart program that you can run in the standalone VM. You get nice output, like this:

✔ testArithmetics

1 test out of total 1 test
1 test passed, 0 tests failed, 0 tests skipped, 0 tests in error

More informations

While this is the essence of Detester, you can get a little more. Read: