]> git.ozlabs.org Git - ccan/blobdiff - container_of/test/run.c
Fix up most #include "tap.h" -> #include "tap/tap.h" in tests.
[ccan] / container_of / test / run.c
index dab462bc4a5bf1541eddb9267caf252339757f20..dd57204d88f839bd15bbe16c3177c9871e00d492 100644 (file)
@@ -12,8 +12,10 @@ int main(int argc, char *argv[])
        int *intp = &foo.a;
        char *charp = &foo.b;
 
-       plan_tests(2);
+       plan_tests(4);
        ok1(container_of(intp, struct foo, a) == &foo);
        ok1(container_of(charp, struct foo, b) == &foo);
+       ok1(container_of_var(intp, &foo, a) == &foo);
+       ok1(container_of_var(charp, &foo, b) == &foo);
        return exit_status();
 }