From: Yann Collet Date: Fri, 29 Sep 2017 01:27:22 +0000 (-0700) Subject: zstreamtest : run unit tests only during "normal" session X-Git-Tag: v1.3.2~3^2~21^2~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=47c6a95d0786edad1910a62b620babe739fe218f;p=thirdparty%2Fzstd.git zstreamtest : run unit tests only during "normal" session not during --mt, --newapi and --opaque this avoids running them 4x during `make test` --- diff --git a/tests/zstreamtest.c b/tests/zstreamtest.c index 6ae4ef96c..16f514425 100644 --- a/tests/zstreamtest.c +++ b/tests/zstreamtest.c @@ -1614,9 +1614,9 @@ int main(int argc, const char** argv) /* Parsing commands. Aggregated commands are allowed */ if (argument[0]=='-') { - if (!strcmp(argument, "--mt")) { selected_api=mt_api; continue; } - if (!strcmp(argument, "--newapi")) { selected_api=advanced_api; continue; } - if (!strcmp(argument, "--opaqueapi")) { selected_api=advanced_api; useOpaqueAPI = 1; continue; } + if (!strcmp(argument, "--mt")) { selected_api=mt_api; testNb += !testNb; continue; } + if (!strcmp(argument, "--newapi")) { selected_api=advanced_api; testNb += !testNb; continue; } + if (!strcmp(argument, "--opaqueapi")) { selected_api=advanced_api; testNb += !testNb; useOpaqueAPI = 1; continue; } if (!strcmp(argument, "--no-big-tests")) { bigTests=0; continue; } argument++;