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

Unified Diff: test/runner/loader_test.dart

Issue 979513002: pkg/unittest: Add a server for serving test assets to browsers. (Closed) Base URL: git@github.com:dart-lang/unittest@master
Patch Set: Fix libDir. Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
« lib/src/runner/loader.dart ('K') | « test/io.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/runner/loader_test.dart
diff --git a/test/runner/loader_test.dart b/test/runner/loader_test.dart
index 9318106d934764b16eaf016127e3acde2fd5b930..bbf6e30c792b5006db85d3608eec00f7414c118e 100644
--- a/test/runner/loader_test.dart
+++ b/test/runner/loader_test.dart
@@ -79,9 +79,14 @@ void main() {
test("throws a nice error if the package root doesn't exist", () {
var loader = new Loader();
- expect(() => loader.loadFile(p.join(_sandbox, 'a_test.dart')),
- throwsA(isLoadException(
- "Directory ${p.join(_sandbox, 'packages')} does not exist.")));
+ expect(() {
+ try {
+ loader.loadFile(p.join(_sandbox, 'a_test.dart'));
+ } finally {
+ loader.close();
+ }
+ }, throwsA(isLoadException(
+ "Directory ${p.join(_sandbox, 'packages')} does not exist.")));
});
});
« lib/src/runner/loader.dart ('K') | « test/io.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698