def METHOD_NAME(self):
    invitations = [
        Invitation('A'),
        Invitation('B'),
    ]
    create_registry_for_test(self.user, self.domain, invitations, grants=[Grant("B", ["A"])], name="reg1")
    self.assertEqual(
        {"reg1"},
        {reg.slug for reg in DataRegistry.objects.accessible_to_domain('A', has_grants=True)}
    )
    # B has no grants
    self.assertEqual(0, len(DataRegistry.objects.accessible_to_domain('B', has_grants=True)))