From 511a0fa7605e61f90e524edfbcbefa230573e32f Mon Sep 17 00:00:00 2001 From: Andrey Zelenkov Date: Thu, 6 Sep 2018 20:18:33 +0300 Subject: Tests: used relative path for configuration. --- test/unit.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'test/unit.py') diff --git a/test/unit.py b/test/unit.py index 973a69b7..58c8327d 100644 --- a/test/unit.py +++ b/test/unit.py @@ -334,8 +334,8 @@ class TestUnitControl(TestUnitHTTP): if isinstance(conf, dict): conf = json.dumps(conf) - if path != '/config': - path = '/config' + path + if path[:1] != '/': + path = '/config/' + path return json.loads(self.put( url=path, @@ -345,8 +345,8 @@ class TestUnitControl(TestUnitHTTP): )['body']) def conf_get(self, path='/config'): - if path != '/config': - path = '/config' + path + if path[:1] != '/': + path = '/config/' + path return json.loads(self.get( url=path, @@ -355,8 +355,8 @@ class TestUnitControl(TestUnitHTTP): )['body']) def conf_delete(self, path='/config'): - if path != '/config': - path = '/config' + path + if path[:1] != '/': + path = '/config/' + path return json.loads(self.delete( url=path, -- cgit