def METHOD_NAME(cls):
    super().METHOD_NAME()
    cls._exit_stack.enter_context(
        unittest.mock.patch.object(
            torch._dynamo.config, "replay_record_enabled", True
        )
    )
    torch._logging.set_logs(graph_breaks=True, dynamo=logging.ERROR)
    # Most of the tests are checking to see if errors got logged, so we
    # ask for errors to be suppressed
    cls._exit_stack.enter_context(
        unittest.mock.patch.object(torch._dynamo.config, "suppress_errors", True)
    )
    cls._exit_stack.enter_context(
        unittest.mock.patch.object(
            torch._dynamo.config,
            "debug_dir_root",
            "/tmp/_torchdynamo_debug_/",
        )
    )