expected_output 1.2.2

Dart native

Easily write and test multiline input and expected output, and avoid test case data clutter in your test logic.

example/example.dart

// Copyright (c) 2019, the Dart project authors.  Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.

library touppercase.tests;

import 'package:expected_output/expected_output.dart';
import 'package:test/test.dart';

void main() {
  for (var dataCase in dataCasesUnder(library: #touppercase.tests)) {
    test(dataCase.testDescription, () {
      var actualOutput = dataCase.input.toUpperCase();
      expect(actualOutput, equals(dataCase.expectedOutput));
    });
  }
}
0
likes
100
pub points
32%
popularity

Easily write and test multiline input and expected output, and avoid test case data clutter in your test logic.

Repository (GitHub)
View/report issues

Documentation

API reference

Uploader

srawlins@google.com

License

BSD (LICENSE)

Dependencies

path, pedantic, test

More

Packages that depend on expected_output