def METHOD_NAME(self, mock_post):
    self.site = models.Site.objects.get(pk=1)
    self.service = models.Service.objects.get(pk=1)
    self.project = models.Project.objects.get(pk=1)
    clause = "up{%s}" % macro.EXCLUSION_MACRO
    rules = {
        "common": {"assert": 'up{service!~"test-service"}'},
        "service": {"assert": 'up{service="test-service",project!~"test-project"}'},
        "project": {"assert": 'up{service="test-service",project="test-project",}'},
    }
    common_rule = models.Rule.objects.create(
        name="Common", clause=clause, duration="1s", obj=self.site
    )
    rules["common"]["model"] = models.Rule.objects.get(pk=common_rule.pk)
    service_rule = common_rule.copy_to("service", self.service.id)
    rules["service"]["model"] = models.Rule.objects.get(pk=service_rule.pk)
    project_rule = service_rule.copy_to("project", self.project.id)
    rules["project"]["model"] = models.Rule.objects.get(pk=project_rule.pk)
    for k, r in rules.items():
        self.assertEqual(macro.rulemacro(r["model"]), r["assert"], "Expansion wrong for %s" % k)