diff options
author | 2018-09-06 09:04:35 +0800 | |
---|---|---|
committer | 2018-09-06 09:04:35 +0800 | |
commit | 5012c278224472d7964e3e8abd9392c06869ded4 (patch) | |
tree | f898dd53282448889f59e17c4d62f3efed290914 /tests/unit/post | |
parent | 776d2061bedda81278b421afde1b3d11cf48266e (diff) |
Fix unittest
openrc was changed in [1]
[1] https://gerrit.opnfv.org/gerrit/#/c/59839/
Change-Id: I30191475ce9a1b27a66d147519583d80b158547a
Signed-off-by: Alex Yang <yangyang1@zte.com.cn>
Diffstat (limited to 'tests/unit/post')
-rw-r--r-- | tests/unit/post/test_post_execute.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/tests/unit/post/test_post_execute.py b/tests/unit/post/test_post_execute.py index 55e345a2..0ca00941 100644 --- a/tests/unit/post/test_post_execute.py +++ b/tests/unit/post/test_post_execute.py @@ -169,9 +169,12 @@ def test__config_kolla_admin_openrc(globals_file_name, openrc_conf_file_dir, tmp elif globals_file_name == 'globals_odl.yml': diff = DeepDiff(src_openrc_lines, dst_openrc_lines, ignore_order=True) assert len(diff) == 1 and diff.get('iterable_item_added') is not None - assert len(diff['iterable_item_added']) == 1 - for val in diff['iterable_item_added'].values(): - assert 'export SDN_CONTROLLER_IP' in val + assert len(diff['iterable_item_added']) == 3 + diffvals = ','.join(diff['iterable_item_added'].values()) + assert 'export SDN_CONTROLLER_IP' in diffvals + assert 'export SDN_CONTROLLER_WEBPORT=' in diffvals + assert 'export SDN_CONTROLLER_RESTCONFPORT=' in diffvals + tmpdir.remove() |