2021-10-25 19:45 (UTC-0700), Jie Zhou: > - Include rte_os_shim.h > - Replace sleep and usleep with rte_delay_us_sleep > - #ifndef RTE_EXEC_ENV_WINDOWS for POSIX code only > > Signed-off-by: Jie Zhou <j...@linux.microsoft.com> > ---
This patch can be combined with the previous one: they serve the same purpose---to remove Unix-specific code. Please try to summarize in the commit message which parts of the tests suites are excluded, e.g. multi-process. It is more useful then stating what was changed in the code. [...] > diff --git a/app/test/test_cmdline.c b/app/test/test_cmdline.c > index 115bee966d..9a76bd299f 100644 > --- a/app/test/test_cmdline.c > +++ b/app/test/test_cmdline.c > @@ -31,6 +31,7 @@ test_cmdline(void) > return -1; > if (test_parse_num_invalid_param() < 0) > return -1; > +#ifndef RTE_EXEC_ENV_WINDOWS > printf("Testing parsing IP addresses...\n"); > if (test_parse_ipaddr_valid() < 0) > return -1; > @@ -38,6 +39,7 @@ test_cmdline(void) > return -1; > if (test_parse_ipaddr_invalid_param() < 0) > return -1; > +#endif > printf("Testing parsing strings...\n"); > if (test_parse_string_valid() < 0) > return -1; What's wrong with parsing IP addresses on Windows? [...] > diff --git a/app/test/test_mp_secondary.c b/app/test/test_mp_secondary.c > index 5b6f05dbb1..da035348bd 100644 > --- a/app/test/test_mp_secondary.c > +++ b/app/test/test_mp_secondary.c > @@ -14,7 +14,9 @@ > #include <errno.h> > #include <string.h> > #include <unistd.h> > +#ifndef RTE_EXEC_ENV_WINDOWS > #include <sys/wait.h> > +#endif > #include <libgen.h> > #include <dirent.h> > #include <limits.h> <libgen.h> is absent on Windows for sure, but you don't exclude it. Does this file even need modification? It's not going to be compiled for Windows. [...] > diff --git a/app/test/test_ring_stress.c b/app/test/test_ring_stress.c > index 1af45e0fc8..ce3535c6b2 100644 > --- a/app/test/test_ring_stress.c > +++ b/app/test/test_ring_stress.c > @@ -43,9 +43,10 @@ test_ring_stress(void) > n += test_ring_rts_stress.nb_case; > k += run_test(&test_ring_rts_stress); > > +#ifndef RTE_EXEC_ENV_WINDOWS > n += test_ring_hts_stress.nb_case; > k += run_test(&test_ring_hts_stress); > - > +#endif Can you please elaborate what is the issue with this case? It is also one of the details you usually want to put into the commit message.