def test_filter_entities_with_username_group_acl(self):
        """Test that filter() takes group ACLs into account"""
        entities, total = entity.Entity.filter({}, user=self.user1)
        self.assertEqual(len(entities), 0)
        self.assertEqual(total, 0)

        self.user1.link_to_acl(self.group1, roles.Role.READER)
        self.group1.link_to_acl(self.entity1, roles.Role.READER)
        entities, total = entity.Entity.filter({}, user=self.user1)
        self.assertEqual(len(entities), 1)
        self.assertEqual(total, 1)
Test that filter() takes group ACLs into account
tests/schemas/rbac.py