def test_get_missing(self):
        missing, target = ExpedientPermission.objects.get_missing(
            self.u1, ["can_get_x2", "can_get_x3"],
            PermissionTestClass.objects.all())
        
        self.assertTrue(target == self.objs[0])
        self.assertTrue(
            missing == ExpedientPermission.objects.get(name="can_get_x3"))
        
        missing, target = ExpedientPermission.objects.get_missing(
            self.u1, ["can_get_x2", "can_read_val"],
            PermissionTestClass.objects.all())
        
        self.assertTrue(target == None and missing == None)

        missing, target = ExpedientPermission.objects.get_missing(
            self.o3, ["can_get_x2", "can_read_val"],
            PermissionTestClass.objects.all())
        
        self.assertTrue(target == self.objs[1] and\
                        missing == ExpedientPermission.objects.get(
                            name="can_get_x2"))
        
        missing, target = ExpedientPermission.objects.get_missing(
            self.su, ["can_get_x2", "can_read_val"],
            PermissionTestClass.objects.all())
        
        self.assertTrue(target == None)
        self.assertTrue(missing == None)
Tests that the get_missing method of L{models.ExpedientPermissionManager}
dataset/ETHPy150Open fp7-ofelia/ocf/expedient/src/python/expedient/common/permissions/tests/tests.py/TestObjectPermissions.test_get_missing