X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=tests%2Flibsmack-tests%2Ftest_cases.cpp;h=503cb7ee42d96c269dc77a377f93744a1777f31b;hb=085ef65e4f5f9782e103dcd422f618c27efc7887;hp=a864a360def1cbbeb7592e11c834cf6e5884f039;hpb=608b7cbb902a2258dd90d961545ae98d367652c6;p=platform%2Fcore%2Ftest%2Fsecurity-tests.git diff --git a/tests/libsmack-tests/test_cases.cpp b/tests/libsmack-tests/test_cases.cpp index a864a36..503cb7e 100644 --- a/tests/libsmack-tests/test_cases.cpp +++ b/tests/libsmack-tests/test_cases.cpp @@ -101,7 +101,8 @@ void clean_up() bool checkNoAccesses(const char *subject, const char *object) { int result; - for(const auto &perm : std::vector () = {"r", "w", "a","t", "l"}) { + + for(const auto &perm : std::vector {"r", "w", "a","t", "l"}) { result = smack_have_access(subject, object, perm.c_str()); if (result == 1) { return false; @@ -529,9 +530,9 @@ RUNNER_TEST_SMACK(smack02_aplying_rules_into_kernel) //should have no access - wrong rule, should be "r" only result = smack_have_access("reader", "book", "rwx"); RUNNER_ASSERT_MSG_BT(result == 0, "Error while checking Smack access"); - //should fail - rule not exist + //should have no access - rule not exist result = smack_have_access("s02badsubjectlabel", "book", "rwx"); - RUNNER_ASSERT_MSG_BT(result == -1, "Error while checking Smack access"); + RUNNER_ASSERT_MSG_BT(result == 0, "Error while checking Smack access"); //this subject do not exist in kernel rules result = smack_revoke_subject("s02nonexistinglabel");