| Index: lib/unittest/unittest.dart
|
| ===================================================================
|
| --- lib/unittest/unittest.dart (revision 9065)
|
| +++ lib/unittest/unittest.dart (working copy)
|
| @@ -242,6 +242,13 @@
|
| }
|
|
|
| /**
|
| + * The regexp pattern filter which constrains which tests to run
|
| + * based on their descriptions.
|
| + */
|
| +
|
| +String filter = null;
|
| +
|
| +/**
|
| * Creates a new test case with the given description and body. The
|
| * description will include the descriptions of any surrounding group()
|
| * calls.
|
| @@ -641,6 +648,10 @@
|
| if (_soloTest != null) {
|
| _tests = _tests.filter((t) => t == _soloTest);
|
| }
|
| + if (filter != null) {
|
| + RegExp re = new RegExp(filter);
|
| + _tests = _tests.filter((t) => re.hasMatch(t.description));
|
| + }
|
|
|
| _config.onStart();
|
|
|
|
|