Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(1)  |  Call(1)  |  Derive(0)  |  Import(0)

src/d/i/diy-lisp-HEAD/tests/test_4_working_with_variables_and_environments.py   diy-lisp(Download)
def test_extend_returns_new_environment():
    """The extend method should create a new environment, leaving the old one unchanged."""
 
    env = Environment({"foo": 1})
    extended = env.extend({"foo": 2})