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

Unified Diff: pkg/unittest/unittest.dart

Issue 11103015: Added the ability for testrunner to start the HTTP server with a random port and communicate that p… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | utils/testrunner/http_server.dart » ('j') | utils/testrunner/pipeline_utils.dart » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/unittest/unittest.dart
===================================================================
--- pkg/unittest/unittest.dart (revision 13499)
+++ pkg/unittest/unittest.dart (working copy)
@@ -219,6 +219,15 @@
TestCase _soloTest;
/**
+ * A map that can be used to communicate state between a test driver
+ * or main() function and the tests, particularly when these two
+ * are otherwise independent. For example, a test driver that starts
+ * an HTTP server and then runs tests that access that server could use
+ * this as a way of communicating the server port to the tests.
+ */
+Map testState = {};
+
+/**
* (Deprecated) Evaluates the [function] and validates that it throws an
* exception. If [callback] is provided, then it will be invoked with the
* thrown exception. The callback may do any validation it wants. In addition,
« no previous file with comments | « no previous file | utils/testrunner/http_server.dart » ('j') | utils/testrunner/pipeline_utils.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698