def METHOD_NAME(use_rlock):
    ls = rinterface.baseenv['ls']
    get = rinterface.baseenv['get']
    assert 'foo' not in ls()
    with rinterface.local_context() as lc_a:
        lc_a['foo'] = 123
        assert tuple(get('foo')) == (123, )
        with rinterface.local_context(use_rlock=use_rlock) as lc_b:
            lc_b['foo'] = 456
            assert tuple(get('foo')) == (456, )
        assert tuple(get('foo')) == (123, )
    assert 'foo' not in ls()