Example #1
0
def test_to_dict_yaml(test_spec):
    config = ConfigTree(str(test_spec))
    with test_spec.open() as f:
        yaml_config = yaml.full_load(f)
    assert yaml_config == config.to_dict()
Example #2
0
def test_to_dict_dict():
    test_dict = {'configuration': {'time': {'start': {'year': 2000}}}}
    config = ConfigTree(test_dict)
    assert config.to_dict() == test_dict