From 4988d25084eae57d63b16a6bccb4b3e0f7042e3c Mon Sep 17 00:00:00 2001 From: Iustin Pop Date: Fri, 29 Nov 2019 14:36:29 +0100 Subject: [PATCH] Expand acl_check testing for actual value checks This actually tests upstream, but just "assert a.check()/not a.check()" seems too little. --- tests/test_acls.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/tests/test_acls.py b/tests/test_acls.py index c3e693f..bed405a 100644 --- a/tests/test_acls.py +++ b/tests/test_acls.py @@ -315,7 +315,13 @@ class TestAclExtensions: acl1 = posix1e.ACL(text=BASIC_ACL_TEXT) assert not acl1.check() acl2 = posix1e.ACL() - assert acl2.check() + c = acl2.check() + assert c == (ACL_MISS_ERROR, 0) + assert isinstance(c, tuple) + assert c[0] == ACL_MISS_ERROR + e = acl2.append() + c = acl2.check() + assert c == (ACL_ENTRY_ERROR, 0) def test_applyto(self, subject): """Test the apply_to function""" -- 2.39.5