import datetime
import tests
+import re
from common import TestCommon
from results import PassFailResult
def get_modules(self, build, machine):
modules = super(ProcMgmtTest, self).get_modules(build, machine)
- n = 1
- for i in range(n):
- modules.add_module("proc_mgmt_test", ["core=3", str(i), str(n)])
- # modules.add_module("proc_mgmt_test", ["core=3", "1"])
+ modules.add_module("proc_mgmt_test", ["core=3", "0", "starter"])
return modules
def get_finish_string(self):
return "TEST DONE"
def process_data(self, testdir, rawiter):
+ sleeper = False
+ num_wait = 0
+
for line in rawiter:
- if line.startswith("FAIL:"):
+
+ if line.startswith("Unblocked") and sleeper:
+ num_wait += 1
+ sleeper = False
+ else:
+ sleeper = False
+
+ if line.startswith("Sleeper exit"):
+ sleeper = True
+
+
+ if line.startswith("Failed"):
return PassFailResult(False)
- return PassFailResult(True)
+ if num_wait == 2:
+ return PassFailResult(True)
+ else:
+ return PassFailResult(False)
#define PROC_MGMT_BENCH 1
#define PROC_MGMT_BENCH_MIN_RUNS 20
-// int total_ids;
static errval_t test_spawn(coreid_t core_id, char *argv[],
struct capref *ret_domain_cap)
USER_PANIC("Failed waiting for domain");
}
}
+*/
static inline cycles_t calculate_time(cycles_t tsc_start, cycles_t tsc_end)
{
bench_ctl_destroy(ctl);
}
-*/
int main(int argc, char **argv)
{
}
printf("Unblocked \n");
- /*
printf("Running benchmarks core 0 \n");
run_benchmark_spawn(0);
printf("Running benchmarks core 3 \n");
run_benchmark_spawn(3);
- */
+
printf("TEST DONE\n");
return 0;
}