def METHOD_NAME():
    """ Thread local attribute for validate is removed after exiting the context. """
    with runtime.context(validate=True):
        runtime.log('test', {'test_key': 'test_val'})
        assert runtime._get_validate_flag() == True  # inside the context
    assert hasattr(runtime._THREAD, 'validate') == False  # outside the context