spielwiese
Last change
on this file since a915285 was
113fcd,
checked in by Andreas Steenpaß <steenpas@…>, 13 years ago
|
tests for waitall and waitfirst
git-svn-id: file:///usr/local/Singular/svn/trunk@14079 2c84dea3-7e68-4137-9b89-c4e89433aadc
|
-
Property mode set to
100644
|
File size:
438 bytes
|
Line | |
---|
1 | LIB "tst.lib"; |
---|
2 | tst_init(); |
---|
3 | |
---|
4 | link l1 = "ssi:fork"; open(l1); |
---|
5 | link l2 = "ssi:fork"; open(l2); |
---|
6 | link l3 = "ssi:fork"; open(l3); |
---|
7 | list l = list(l1,l2,l3); |
---|
8 | write(l1, quote(system("sh", "sleep 15"))); |
---|
9 | write(l2, quote(system("sh", "sleep 10"))); |
---|
10 | write(l3, quote(system("sh", "sleep 11"))); |
---|
11 | waitall(l, 5000); // terminates after 5sec with result 0 |
---|
12 | waitall(l); // terminates after 10 more sec |
---|
13 | close(l1); |
---|
14 | close(l2); |
---|
15 | close(l3); |
---|
16 | |
---|
17 | tst_status(1);$ |
---|
Note: See
TracBrowser
for help on using the repository browser.