diff options
author | Benjamin Schubert <contact@benschubert.me> | 2019-06-11 22:55:29 +0100 |
---|---|---|
committer | Benjamin Schubert <ben.c.schubert@gmail.com> | 2019-06-13 16:05:52 +0100 |
commit | 4ace73c0a9c7e15e544b40eb378d7c4712ab0872 (patch) | |
tree | 1e999672d53e738489be276314a9edd5e403b633 /tests/internals/yaml.py | |
parent | d792c7be809d3e37f440c4cf012f353f76ba69e9 (diff) | |
download | buildstream-bschubert/node-api.tar.gz |
replace node_set for MappingNodebschubert/node-api
Diffstat (limited to 'tests/internals/yaml.py')
-rw-r--r-- | tests/internals/yaml.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/internals/yaml.py b/tests/internals/yaml.py index 2f87d471b..4fb46cd89 100644 --- a/tests/internals/yaml.py +++ b/tests/internals/yaml.py @@ -127,7 +127,7 @@ def test_node_set(datafiles): base = _yaml.load(filename) assert 'mother' not in base - _yaml.node_set(base, 'mother', 'snow white') + base['mother'] = 'snow white' assert base.get_scalar('mother').as_str() == 'snow white' @@ -142,12 +142,12 @@ def test_node_set_overwrite(datafiles): # Overwrite a string assert base.get_scalar('kind').as_str() == 'pony' - _yaml.node_set(base, 'kind', 'cow') + base['kind'] = 'cow' assert base.get_scalar('kind').as_str() == 'cow' # Overwrite a list as a string assert _yaml.node_get(base, list, 'moods') == ['happy', 'sad'] - _yaml.node_set(base, 'moods', 'unemotional') + base['moods'] = 'unemotional' assert base.get_scalar('moods').as_str() == 'unemotional' |