# HG changeset patch # User Paul Boddie # Date 1615159913 -3600 # Node ID 3440a225101f96274ae5d7b5c8dc1dd3d1d73da2 # Parent 2bd7137bfc8ef295d73743d167a7fa22637edb76 Show the elapsed time for the test. diff -r 2bd7137bfc8e -r 3440a225101f dstest_test_client.cc --- a/dstest_test_client.cc Mon Mar 08 00:31:01 2021 +0100 +++ b/dstest_test_client.cc Mon Mar 08 00:31:53 2021 +0100 @@ -25,6 +25,7 @@ #include #include #include +#include #include @@ -189,6 +190,7 @@ /* Start threads accessing all the files. */ + time_t t = time(NULL); int current = 0; for (fileid = 0; fileid < NUMBER_OF_FILES; fileid++) @@ -209,7 +211,8 @@ for (fileid = 0; fileid < NUMBER_OF_FILES; fileid++) file_close(&contexts[fileid]); - printf("Activities completed.\n"); + t = time(NULL) - t; + printf("Activities completed in %ld seconds.\n", t); return 0; }