X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fdaemon%2Futils_subst_test.c;h=ec2e3514f2d11f4d14c1ff246478281b0da17db7;hb=6164fe4456716e6dc36aaa2ab617b104a7ac5ff3;hp=751976630fb87e0819053bf123b728f71e6aca29;hpb=9a8d9ab6a8c2e4d20a2b946bdfc2035bb92bccb6;p=collectd.git diff --git a/src/daemon/utils_subst_test.c b/src/daemon/utils_subst_test.c index 75197663..ec2e3514 100644 --- a/src/daemon/utils_subst_test.c +++ b/src/daemon/utils_subst_test.c @@ -24,11 +24,15 @@ * Florian octo Forster */ -#include "testing.h" -#include "collectd.h" #include "common.h" /* for STATIC_ARRAY_SIZE */ +#include "collectd.h" +#include "testing.h" #include "utils_subst.h" +#if HAVE_LIBKSTAT +kstat_ctl_t *kc; +#endif /* HAVE_LIBKSTAT */ + DEF_TEST(subst) { struct { @@ -82,7 +86,7 @@ DEF_TEST(subst) } OK(subst (buffer, sizeof (buffer), cases[i].str, cases[i].off1, cases[i].off2, cases[i].rplmt) == &buffer[0]); - STREQ(cases[i].want, buffer); + EXPECT_EQ_STR(cases[i].want, buffer); } return 0; @@ -112,7 +116,7 @@ DEF_TEST(subst_string) } OK(subst_string (buffer, sizeof (buffer), cases[i].str, cases[i].srch, cases[i].rplmt) == buffer); - STREQ(cases[i].want, buffer); + EXPECT_EQ_STR(cases[i].want, buffer); } return 0;