| OLD | NEW |
| 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 import 'dart:collection'; | 6 import 'dart:collection'; |
| 7 | 7 |
| 8 import 'package:test/src/backend/declarer.dart'; | 8 import 'package:test/src/backend/declarer.dart'; |
| 9 import 'package:test/src/backend/group.dart'; | 9 import 'package:test/src/backend/group.dart'; |
| 10 import 'package:test/src/backend/group_entry.dart'; | 10 import 'package:test/src/backend/group_entry.dart'; |
| (...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 298 expect(success, isTrue); | 298 expect(success, isTrue); |
| 299 } | 299 } |
| 300 | 300 |
| 301 /// Runs [body] with a declarer and returns the declared entries. | 301 /// Runs [body] with a declarer and returns the declared entries. |
| 302 List<GroupEntry> declare(void body()) { | 302 List<GroupEntry> declare(void body()) { |
| 303 var declarer = new Declarer()..declare(body); | 303 var declarer = new Declarer()..declare(body); |
| 304 return declarer.build().entries; | 304 return declarer.build().entries; |
| 305 } | 305 } |
| 306 | 306 |
| 307 /// Runs [body] with a declarer and returns an engine that runs those tests. | 307 /// Runs [body] with a declarer and returns an engine that runs those tests. |
| 308 Engine declareEngine(void body()) { | 308 Engine declareEngine(void body(), {bool runSkipped: false}) { |
| 309 var declarer = new Declarer()..declare(body); | 309 var declarer = new Declarer()..declare(body); |
| 310 return new Engine.withSuites([ | 310 return new Engine.withSuites([ |
| 311 new RunnerSuite(const PluginEnvironment(), declarer.build()) | 311 new RunnerSuite(const PluginEnvironment(), declarer.build()) |
| 312 ]); | 312 ], runSkipped: runSkipped); |
| 313 } | 313 } |
| OLD | NEW |