mirror of
https://github.com/httprunner/httprunner.git
synced 2026-05-21 16:23:16 +08:00
fix #64: when headers in test is None, it should inherit from config
This commit is contained in:
@@ -163,12 +163,12 @@ class TestUtils(ApiServerUnittest):
|
||||
functions_mapping["endswith"](12345, 45)
|
||||
|
||||
def test_deep_update_dict(self):
|
||||
origin_dict = {'a': 1, 'b': {'c': 3, 'd': 4}, 'f': 6}
|
||||
override_dict = {'a': 2, 'b': {'c': 33, 'e': 5}, 'g': 7}
|
||||
origin_dict = {'a': 1, 'b': {'c': 3, 'd': 4}, 'f': 6, 'h': 123}
|
||||
override_dict = {'a': 2, 'b': {'c': 33, 'e': 5}, 'g': 7, 'h': None}
|
||||
updated_dict = utils.deep_update_dict(origin_dict, override_dict)
|
||||
self.assertEqual(
|
||||
updated_dict,
|
||||
{'a': 2, 'b': {'c': 33, 'd': 4, 'e': 5}, 'f': 6, 'g': 7}
|
||||
{'a': 2, 'b': {'c': 33, 'd': 4, 'e': 5}, 'f': 6, 'g': 7, 'h': 123}
|
||||
)
|
||||
|
||||
def test_get_imported_module(self):
|
||||
|
||||
Reference in New Issue
Block a user