Example #1
0
 void RunTest(int line,
              const char *haystack,
              const char *needle,
              const char *expected)
 {
     RunTestImpl(line,
                 haystack, StrLen(haystack),
                 needle,   StrLen(needle),
                 expected);
 }
Example #2
0
 void RunTest(int line,
              const char *haystack,
              const char *needle,
              size_t needle_len,
              const char *expected)
 {
     RunTestImpl(line,
                 haystack, StrLen(haystack),
                 needle,   needle_len,
                 expected);
 }
Example #3
0
 void RunTest(int line,
              const char *haystack,
              size_t haystack_len,
              const char *needle,
              const char *expected)
 {
     RunTestImpl(line,
                 haystack, haystack_len,
                 needle,   StrLen(needle),
                 expected);
 }
inline 
void CalcSequentialTime ( void (*pfn)() ) {
    util::sequential_time = RunTestImpl(NULL, pfn) / util::num_threads;
}
/** If histogramFileName is a string, the histogram of individual runs is generated and stored
    in a file with the given name. If it is NULL then the histogram is printed on the console.
    By default no histogram is generated. 
    The histogram format is: "rate bucket start" "number of tests in this bucket". **/
inline 
void RunTest ( const char* title_fmt, size_t workload_param, void (*pfn_test)(), char* histogramFileName = no_histogram ) {
    char title[1024];
    sprintf(title, title_fmt, (long)workload_param);
    RunTestImpl(title, pfn_test, histogramFileName);
}