From 1ac9137f117a0e4dfa54c9f4e7f7c2a0ffa727c6 Mon Sep 17 00:00:00 2001 From: Kenneth Hoste Date: Tue, 7 Apr 2020 13:20:18 +0200 Subject: [PATCH] fix test_det_pr_target_repo, take into account that __file__ may point to github.pyc... --- test/framework/github.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/framework/github.py b/test/framework/github.py index 4ddce65e38..bd1e7cecd4 100644 --- a/test/framework/github.py +++ b/test/framework/github.py @@ -718,8 +718,8 @@ def test_det_pr_target_repo(self): # if only Python files are involved, result is easyblocks or framework repo; # all Python files are easyblocks => easyblocks repo, otherwise => framework repo; # files are opened and inspected here to discriminate between easyblocks & other Python files, so must exist! - github_py = os.path.abspath(__file__) - testdir = os.path.dirname(github_py) + testdir = os.path.dirname(os.path.abspath(__file__)) + github_py = os.path.join(testdir, 'github.py') configuremake = os.path.join(testdir, 'sandbox', 'easybuild', 'easyblocks', 'generic', 'configuremake.py') self.assertTrue(os.path.exists(configuremake))