| Index: pkg/observe/lib/src/microtask.dart
|
| diff --git a/pkg/observe/test/observe_test_utils.dart b/pkg/observe/lib/src/microtask.dart
|
| similarity index 63%
|
| copy from pkg/observe/test/observe_test_utils.dart
|
| copy to pkg/observe/lib/src/microtask.dart
|
| index 2d4e7cbf63af2cf0de0cc797a7ecfccc39e66bf2..e56fb623d6385b76ce5f785899e202b90d80624d 100644
|
| --- a/pkg/observe/test/observe_test_utils.dart
|
| +++ b/pkg/observe/lib/src/microtask.dart
|
| @@ -2,16 +2,19 @@
|
| // 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 observe.test.observe_test_utils;
|
| +/**
|
| + * *Warning*: this library is **internal**, and APIs are subject to change.
|
| + *
|
| + * Wraps a callback using [wrapMicrotask] and provides the ability to pump all
|
| + * observable objects and [runAsync] calls via [performMicrotaskCheckpoint].
|
| + */
|
| +library observe.src.microtask;
|
|
|
| -import 'dart:async';
|
| -import 'package:observe/observe.dart';
|
| -import 'package:unittest/unittest.dart';
|
| +import 'dart:async' show Completer, runZonedExperimental;
|
| +import 'package:observe/observe.dart' show Observable;
|
|
|
| -// TODO(jmesserly): use matchers when we have a way to compare ChangeRecords.
|
| -// For now just use the toString.
|
| -expectChanges(actual, expected, {reason}) =>
|
| - expect('$actual', '$expected', reason: reason);
|
| +// TODO(jmesserly): remove "microtask" from these names and instead import
|
| +// the library "as microtask"?
|
|
|
| /**
|
| * This change pumps events relevant to observers and data-binding tests.
|
| @@ -57,13 +60,3 @@ wrapMicrotask(void testCase()) {
|
| }, onRunAsync: (callback) => _pending.add(callback));
|
| };
|
| }
|
| -
|
| -/**
|
| - * This is a special kind of unit [test], that supports
|
| - * calling [performMicrotaskCheckpoint] during the test to pump events
|
| - * that original from observable objects.
|
| - */
|
| -observeTest(name, testCase) => test(name, wrapMicrotask(testCase));
|
| -
|
| -/** The [solo_test] version of [observeTest]. */
|
| -solo_observeTest(name, testCase) => solo_test(name, wrapMicrotask(testCase));
|
|
|