diff options
author | hongbo tian <hongbo.tianhongbo@huawei.com> | 2016-12-19 03:01:05 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2016-12-19 03:01:05 +0000 |
commit | dc5216ef3b7833f5f7dfe81919b96f4e8f04280c (patch) | |
tree | 1f32b14284f2d916689835430534af60d4608491 | |
parent | 10f6a7587c18a3b35e731165cee65366d5d6d94f (diff) | |
parent | 3298811ce85e54c3c766ca7cf1e77bfd66956ab5 (diff) |
Merge "dovetail tool: bugfix about setup dovetail"
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | dovetail/compliance/debug.yml | 2 | ||||
-rw-r--r-- | dovetail/conf/dovetail_config.yml | 4 | ||||
-rw-r--r-- | dovetail/testcase.py | 12 | ||||
-rw-r--r-- | setup.cfg | 2 |
5 files changed, 13 insertions, 9 deletions
@@ -1,7 +1,7 @@ *.py[cod] # Packages -*.egg +*.egg* .testrepository dist build diff --git a/dovetail/compliance/debug.yml b/dovetail/compliance/debug.yml index 8cc4b36c..13ba335c 100644 --- a/dovetail/compliance/debug.yml +++ b/dovetail/compliance/debug.yml @@ -4,7 +4,7 @@ debug: name: debug testcases_list: - - dovetail.example.tc002 + - dovetail.example.tc002 - dovetail.ipv6.tc001 - dovetail.nfvi.tc001 - dovetail.nfvi.tc002 diff --git a/dovetail/conf/dovetail_config.yml b/dovetail/conf/dovetail_config.yml index 837f8840..c8f9fbe4 100644 --- a/dovetail/conf/dovetail_config.yml +++ b/dovetail/conf/dovetail_config.yml @@ -9,8 +9,8 @@ creds: '/home/opnfv/dovetail/openstack.creds' # TO DO: once version scheme settled, adjust accordingly repo: 'https://github.com/opnfv/dovetail/tree/master/' -COMPLIANCE_PATH: ./compliance/ -TESTCASE_PATH: ./testcase/ +COMPLIANCE_PATH: compliance/ +TESTCASE_PATH: testcase/ # testsuite supported, should adjust accordingly testsuite_supported: - compliance_set diff --git a/dovetail/testcase.py b/dovetail/testcase.py index 4310f9b4..dd0fd2b5 100644 --- a/dovetail/testcase.py +++ b/dovetail/testcase.py @@ -158,8 +158,10 @@ class Testcase(object): @classmethod def load(cls): - for root, dirs, files in \ - os.walk(dt_cfg.dovetail_config['TESTCASE_PATH']): + testcase_dir = os.path.dirname(os.path.abspath(__file__)) + testcase_path = dt_cfg.dovetail_config['TESTCASE_PATH'] + abs_testcase_path = os.path.join(testcase_dir, testcase_path) + for root, dirs, files in os.walk(abs_testcase_path): for testcase_file in files: with open(os.path.join(root, testcase_file)) as f: testcase_yaml = yaml.safe_load(f) @@ -254,8 +256,10 @@ class Testsuite: @classmethod def load(cls): - for root, dirs, files in \ - os.walk(dt_cfg.dovetail_config['COMPLIANCE_PATH']): + compliance_dir = os.path.dirname(os.path.abspath(__file__)) + compliance_path = dt_cfg.dovetail_config['COMPLIANCE_PATH'] + abs_compliance_path = os.path.join(compliance_dir, compliance_path) + for root, dirs, files in os.walk(abs_compliance_path): for testsuite_yaml in files: with open(os.path.join(root, testsuite_yaml)) as f: testsuite_yaml = yaml.safe_load(f) @@ -4,4 +4,4 @@ home-page = https://wiki.opnfv.org/display/dovetail [entry_points] console_scripts = - dovetail = dovetail.main:main + dovetail = dovetail.run:main |