Module: tools Branch: master Commit: baf733def7e39a18d020dd50f060c870a60be1ac URL: http://source.winehq.org/git/tools.git/?a=commit;h=baf733def7e39a18d020dd50f...
Author: Francois Gouget fgouget@codeweavers.com Date: Sun Jun 18 13:48:42 2017 +0200
testbot/TestLauncher: Trace the time it takes to run each test.
Signed-off-by: Francois Gouget fgouget@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
testbot/src/TestLauncher/TestLauncher.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/testbot/src/TestLauncher/TestLauncher.c b/testbot/src/TestLauncher/TestLauncher.c index 2e9a62f..1d0abac 100644 --- a/testbot/src/TestLauncher/TestLauncher.c +++ b/testbot/src/TestLauncher/TestLauncher.c @@ -283,7 +283,7 @@ static BOOL AllImportedDllsPresent(const char *TestExeName) int main(int argc, char *argv[]) { int Arg; - DWORD TimeOut; + DWORD Start, TimeOut; BOOL UsageError; char TestExeFullName[_MAX_PATH]; char *TestExeFileName; @@ -375,12 +375,14 @@ int main(int argc, char *argv[]) exit(1); }
+ Start = GetTickCount(); printf("%s:%s start - -\n", TestName, Subtest);
if (! AllImportedDllsPresent(TestExeFullName)) { printf("%s: %u tests executed (0 marked as todo, %u failures), %u skipped.\n", TestName, Failures, Failures, Skips); - printf("%s:%s done (%u)\n", TestName, Subtest, Failures); + printf("%s:%s done (%u) in %lds\n", TestName, Subtest, Failures, + (GetTickCount() - Start) / 1000); exit(0); }
@@ -449,7 +451,8 @@ int main(int argc, char *argv[]) } CloseHandle(ProcessInformation.hProcess);
- printf("%s:%s done (%lu)\n", TestName, Subtest, ExitCode); + printf("%s:%s done (%lu) in %lds\n", TestName, Subtest, ExitCode, + (GetTickCount() - Start) / 1000);
return 0; }