def METHOD_NAME(self):
    host_1 = Host.objects.create(
        fqdn="test_host_1",
        prototype=Prototype.objects.create(bundle=self.bundle, type="host"),
        maintenance_mode=MaintenanceMode.ON,
    )
    host_2 = Host.objects.create(
        fqdn="test_host_2",
        prototype=Prototype.objects.create(bundle=self.bundle, type="host"),
        maintenance_mode=MaintenanceMode.ON,
    )
    component = ServiceComponent.objects.create(
        prototype=Prototype.objects.create(
            bundle=self.bundle,
            type="component",
            display_name="test_component",
        ),
        cluster=self.cluster,
        service=self.service,
    )
    HostComponent.objects.create(
        cluster=self.cluster,
        host=host_1,
        service=self.service,
        component=component,
    )
    HostComponent.objects.create(
        cluster=self.cluster,
        host=host_2,
        service=self.service,
        component=component,
    )
    self.assertEqual(self.service.maintenance_mode, MaintenanceMode.ON)
    host_2.maintenance_mode = MaintenanceMode.OFF
    host_2.save(update_fields=["maintenance_mode"])
    self.assertEqual(self.service.maintenance_mode, MaintenanceMode.OFF)