diff options
author | Benjamin Schubert <ben.c.schubert@gmail.com> | 2019-07-02 14:20:52 +0100 |
---|---|---|
committer | Benjamin Schubert <ben.c.schubert@gmail.com> | 2019-07-03 13:55:16 +0100 |
commit | de32e7098236bbea88ff85934d4370de69818583 (patch) | |
tree | 47d4db7fc1dc35e9ad68b78306c08a5c4e8588e7 | |
parent | e89f5a27213831bb50d71ad66eaf6985fad999e0 (diff) | |
download | buildstream-de32e7098236bbea88ff85934d4370de69818583.tar.gz |
tests/yaml: Stop using 'composite_dict' and use 'composite' instead
'composite_dict' is a more internal method and we don't really need to
access it there
-rw-r--r-- | src/buildstream/testing/runcli.py | 2 | ||||
-rw-r--r-- | tests/internals/yaml.py | 14 |
2 files changed, 8 insertions, 8 deletions
diff --git a/src/buildstream/testing/runcli.py b/src/buildstream/testing/runcli.py index 16593fa8e..ad8a09a33 100644 --- a/src/buildstream/testing/runcli.py +++ b/src/buildstream/testing/runcli.py @@ -574,7 +574,7 @@ class CliIntegration(Cli): project_config = _yaml.load(temp_project) - _yaml.composite_dict(base_config, project_config) + _yaml.composite(base_config, project_config) _yaml.roundtrip_dump(base_config, project_filename) diff --git a/tests/internals/yaml.py b/tests/internals/yaml.py index 90f2a39f8..0432a0a84 100644 --- a/tests/internals/yaml.py +++ b/tests/internals/yaml.py @@ -183,7 +183,7 @@ def test_composite_preserve_originals(datafiles): base = _yaml.load(filename) overlay = _yaml.load(overlayfile) base_copy = base.copy() - _yaml.composite_dict(base_copy, overlay) + _yaml.composite(base_copy, overlay) copy_extra = base_copy.get_mapping('extra') orig_extra = base.get_mapping('extra') @@ -249,7 +249,7 @@ def test_list_composition(datafiles, filename, tmpdir, base = _yaml.load(base_file, 'basics.yaml') overlay = _yaml.load(overlay_file, shortname=filename) - _yaml.composite_dict(base, overlay) + _yaml.composite(base, overlay) children = base.get_sequence('children') assert len(children) == length @@ -267,7 +267,7 @@ def test_list_deletion(datafiles): base = _yaml.load(base, shortname='basics.yaml') overlay = _yaml.load(overlay, shortname='listoverwriteempty.yaml') - _yaml.composite_dict(base, overlay) + _yaml.composite(base, overlay) children = base.get_sequence('children') assert not children @@ -384,8 +384,8 @@ def test_list_composition_twice(datafiles, tmpdir, filename1, filename2, overlay1 = _yaml.load(file1, shortname=filename1) overlay2 = _yaml.load(file2, shortname=filename2) - _yaml.composite_dict(base, overlay1) - _yaml.composite_dict(base, overlay2) + _yaml.composite(base, overlay1) + _yaml.composite(base, overlay2) children = base.get_sequence('children') assert len(children) == length @@ -401,8 +401,8 @@ def test_list_composition_twice(datafiles, tmpdir, filename1, filename2, overlay1 = _yaml.load(file1, shortname=filename1) overlay2 = _yaml.load(file2, shortname=filename2) - _yaml.composite_dict(overlay1, overlay2) - _yaml.composite_dict(base, overlay1) + _yaml.composite(overlay1, overlay2) + _yaml.composite(base, overlay1) children = base.get_sequence('children') assert len(children) == length |