Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1141)

Side by Side Diff: test/backend/invoker_test.dart

Issue 1390883002: Make Suite contain a single Group. (Closed) Base URL: git@github.com:dart-lang/test@master
Patch Set: Code review changes Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « test/backend/declarer_test.dart ('k') | test/runner/browser/loader_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 import 'dart:async'; 5 import 'dart:async';
6 6
7 import 'package:fake_async/fake_async.dart'; 7 import 'package:fake_async/fake_async.dart';
8 import 'package:test/src/backend/group.dart';
8 import 'package:test/src/backend/invoker.dart'; 9 import 'package:test/src/backend/invoker.dart';
9 import 'package:test/src/backend/metadata.dart'; 10 import 'package:test/src/backend/metadata.dart';
10 import 'package:test/src/backend/state.dart'; 11 import 'package:test/src/backend/state.dart';
11 import 'package:test/src/backend/suite.dart'; 12 import 'package:test/src/backend/suite.dart';
12 import 'package:test/test.dart'; 13 import 'package:test/test.dart';
13 14
14 import '../utils.dart'; 15 import '../utils.dart';
15 16
16 void main() { 17 void main() {
17 var suite; 18 var suite;
18 setUp(() { 19 setUp(() {
19 lastState = null; 20 lastState = null;
20 suite = new Suite([]); 21 suite = new Suite(new Group.root([]));
21 }); 22 });
22 23
23 group("Invoker.current", () { 24 group("Invoker.current", () {
24 var invoker = Invoker.current; 25 var invoker = Invoker.current;
25 test("returns null outside of a test body", () { 26 test("returns null outside of a test body", () {
26 expect(invoker, isNull); 27 expect(invoker, isNull);
27 }); 28 });
28 29
29 test("returns the current invoker in a test body", () async { 30 test("returns the current invoker in a test body", () async {
30 var invoker; 31 var invoker;
(...skipping 491 matching lines...) Expand 10 before | Expand all | Expand 10 after
522 expect(liveTest.state.status, equals(Status.complete)); 523 expect(liveTest.state.status, equals(Status.complete));
523 expect(isComplete, isFalse); 524 expect(isComplete, isFalse);
524 }); 525 });
525 }); 526 });
526 } 527 }
527 528
528 LocalTest _localTest(body(), {Metadata metadata}) { 529 LocalTest _localTest(body(), {Metadata metadata}) {
529 if (metadata == null) metadata = new Metadata(); 530 if (metadata == null) metadata = new Metadata();
530 return new LocalTest("test", metadata, body); 531 return new LocalTest("test", metadata, body);
531 } 532 }
OLDNEW
« no previous file with comments | « test/backend/declarer_test.dart ('k') | test/runner/browser/loader_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698