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

Unified Diff: tests/standalone/src/io/ProcessExitTest.dart

Issue 9863015: This is a request for comments. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 8 years, 8 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 | « runtime/bin/process_impl.dart ('k') | tests/standalone/src/io/ProcessInvalidArgumentsTest.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/src/io/ProcessExitTest.dart
diff --git a/tests/standalone/src/io/ProcessExitTest.dart b/tests/standalone/src/io/ProcessExitTest.dart
index 4078cd296e2a52fe95a3b743517e56d79320ef32..61a349fdce6d8b9428f3dbc0b5ab7aab3a06f60d 100644
--- a/tests/standalone/src/io/ProcessExitTest.dart
+++ b/tests/standalone/src/io/ProcessExitTest.dart
@@ -8,18 +8,28 @@
#import("dart:io");
#source("ProcessTestUtil.dart");
-class ProcessExitTest {
- static void testExit() {
- Process process = new Process.start(getProcessTestFileName(),
- const ["0", "0", "99", "0"]);
+testExit() {
+ Process process = new Process.start(getProcessTestFileName(),
+ const ["0", "0", "99", "0"]);
- process.onExit = (int exitCode) {
- Expect.equals(exitCode, 99);
- process.close();
- };
- }
+ process.onExit = (int exitCode) {
+ Expect.equals(exitCode, 99);
+ process.close();
+ };
+}
+
+testExitRun() {
+ Process process = new Process.run(getProcessTestFileName(),
+ const ["0", "0", "99", "0"],
+ null,
+ (exit, out, err) {
+ Expect.equals(exit, 99);
+ Expect.equals(out, '');
+ Expect.equals(err, '');
+ });
}
main() {
- ProcessExitTest.testExit();
+ testExit();
+ testExitRun();
}
« no previous file with comments | « runtime/bin/process_impl.dart ('k') | tests/standalone/src/io/ProcessInvalidArgumentsTest.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698