Date: Wed, 23 Dec 2015 09:59:31 +0000 (UTC) From: Garrett Cooper <ngie@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r292650 - head/tests/sys/mac/bsdextended Message-ID: <201512230959.tBN9xV1q077949@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: ngie Date: Wed Dec 23 09:59:31 2015 New Revision: 292650 URL: https://svnweb.freebsd.org/changeset/base/292650 Log: Move mac_bsdextended check up before running the test_libugidfw_strings testcases I realize that these tests could be run before mac_bsdextended is loaded, but it would overcomplicate things to special case handle the testcases before doing the mac_bsdextended(4) feature check The testcases will be split up so they can be run separately in the near future MFC after: 3 days Sponsored by: EMC / Isilon Storage Division Modified: head/tests/sys/mac/bsdextended/ugidfw_test.c Modified: head/tests/sys/mac/bsdextended/ugidfw_test.c ============================================================================== --- head/tests/sys/mac/bsdextended/ugidfw_test.c Wed Dec 23 09:18:47 2015 (r292649) +++ head/tests/sys/mac/bsdextended/ugidfw_test.c Wed Dec 23 09:59:31 2015 (r292650) @@ -208,16 +208,6 @@ main(void) return (0); } - printf("1..%lu\n", nitems(test_users) + nitems(test_groups) + - 3 * nitems(test_strings) + 2); - - /* - * We can test some parts of the library without the MAC Framework - * and policy loaded, so run those tests before calling - * mac_is_present(). - */ - test_libugidfw_strings(); - switch (mac_is_present("bsdextended")) { case -1: printf("1..0 # SKIP mac_is_present failed: %s\n", @@ -231,6 +221,16 @@ main(void) return (0); } + printf("1..%lu\n", nitems(test_users) + nitems(test_groups) + + 3 * nitems(test_strings) + 2); + + /* + * We can test some parts of the library without the MAC Framework + * and policy loaded, so run those tests before calling + * mac_is_present(). + */ + test_libugidfw_strings(); + /* * Some simple up-front checks to see if we're able to query the * policy for basic state. We want the rule count to be 0 before
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201512230959.tBN9xV1q077949>