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

Unified Diff: tests/isolate/spawn_uri_exported_main_test.dart

Issue 864233003: Fix http://dartbug.com/22115 (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 11 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
« no previous file with comments | « tests/isolate/spawn_uri_exported_main_lib.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/isolate/spawn_uri_exported_main_test.dart
===================================================================
--- tests/isolate/spawn_uri_exported_main_test.dart (revision 0)
+++ tests/isolate/spawn_uri_exported_main_test.dart (working copy)
@@ -0,0 +1,20 @@
+import "dart:async";
+import "dart:isolate";
+import "package:expect/expect.dart";
+
+main() {
+ print("Spawning isolate.");
+ var t = new Timer(new Duration(seconds:5), () {
+ Expect.fail("Isolate was not spawned successfully.");
+ });
+ var rp = new RawReceivePort();
+ rp.handler = (msg) {
+ print("Spawned main called.");
+ Expect.equals(msg, 50);
+ rp.close();
+ };
+ Isolate.spawnUri(Uri.parse("spawn_uri_exported_main.dart"), null, rp.sendPort).then((_) {
+ print("Loaded");
+ t.cancel();
+ });
+}
« no previous file with comments | « tests/isolate/spawn_uri_exported_main_lib.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698