allow to give only a part as parameter to ./test

This commit is contained in:
Steffen Jaeckel 2017-06-20 12:11:16 +02:00
parent 36132b016f
commit b03b93099d

View File

@ -351,7 +351,7 @@ int main(int argc, char **argv)
dur = epoch_usec();
for (i = 0; i < sizeof(test_functions)/sizeof(test_functions[0]); ++i) {
if (single_test && strcmp(test_functions[i].name, single_test)) {
if (single_test && strstr(test_functions[i].name, single_test) == NULL) {
continue;
}
dots = fn_len - strlen(test_functions[i].name);