Fix return value of smack_have_access
[platform/core/test/security-tests.git] / tests / libsmack-tests / test_cases.cpp
index ae1d8bf..503cb7e 100644 (file)
@@ -530,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");