def METHOD_NAME(self) -> None:
    # The default main process is subscribed to the USER_IP channel.
    worker2 = self.make_worker_hs(
        "synapse.app.generic_worker",
        extra_config={
            "worker_name": "worker2",
            "run_background_tasks_on": "worker1",
            "redis": {"enabled": True},
        },
    )
    self.assertNotIn(
        "USER_IP",
        worker2.get_replication_command_handler()._channels_to_subscribe_to,
    )
    # Advance so the Redis subscription gets processed
    self.pump(0.1)
    # The count is 2 because both the main process and the worker are subscribed.
    self.assertEqual(len(self._redis_server._subscribers_by_channel[b"test"]), 2)
    # For USER_IP, the count is 1 because only the main process is subscribed.
    self.assertEqual(
        len(self._redis_server._subscribers_by_channel[b"test/USER_IP"]), 1
    )