From 8ffc7049b5a13fb3ff4520254fb788268d4f79de Mon Sep 17 00:00:00 2001 From: Celso Providelo Date: Thu, 5 Feb 2015 08:04:39 -0500 Subject: [PATCH 1/2] Test fixing (proposal) --- boottest.py | 5 +++-- tests/test_boottest.py | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/boottest.py b/boottest.py index 3feae36..6a7ad63 100644 --- a/boottest.py +++ b/boottest.py @@ -130,8 +130,9 @@ class BootTest(object): "RUNNING": 'Test in progress', } - script_path = os.path.expanduser( - "~/auto-package-testing/jenkins/boottest-britney") + #script_path = os.path.expanduser( + # "~/auto-package-testing/jenkins/boottest-britney") + script_path = 'boottest/jenkins/boottest-britney' def __init__(self, britney, distribution, series, debug=False): self.britney = britney diff --git a/tests/test_boottest.py b/tests/test_boottest.py index 27ff43a..7442156 100644 --- a/tests/test_boottest.py +++ b/tests/test_boottest.py @@ -156,7 +156,7 @@ class TestBoottestEnd2End(TestBase): """Create a manifest for this britney run context.""" path = os.path.join( self.data.path, - 'boottest/images/ubuntu/{}'.format(self.data.series)) + 'boottest/images/ubuntu-touch/{}'.format(self.data.series)) create_manifest(path, lines) def make_boottest(self): From df62c7fcf7b4c17b5d1307abddd4e0655cd7a39b Mon Sep 17 00:00:00 2001 From: Celso Providelo Date: Thu, 5 Feb 2015 08:15:07 -0500 Subject: [PATCH 2/2] solve '~' expansion for tests. --- boottest.py | 5 ++--- tests/test_boottest.py | 4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/boottest.py b/boottest.py index 6a7ad63..3feae36 100644 --- a/boottest.py +++ b/boottest.py @@ -130,9 +130,8 @@ class BootTest(object): "RUNNING": 'Test in progress', } - #script_path = os.path.expanduser( - # "~/auto-package-testing/jenkins/boottest-britney") - script_path = 'boottest/jenkins/boottest-britney' + script_path = os.path.expanduser( + "~/auto-package-testing/jenkins/boottest-britney") def __init__(self, britney, distribution, series, debug=False): self.britney = britney diff --git a/tests/test_boottest.py b/tests/test_boottest.py index 7442156..8a588b9 100644 --- a/tests/test_boottest.py +++ b/tests/test_boottest.py @@ -161,8 +161,8 @@ class TestBoottestEnd2End(TestBase): def make_boottest(self): """Create a stub version of boottest-britney script.""" - script_path = os.path.join( - self.data.path, 'boottest/jenkins/boottest-britney') + script_path = os.path.expanduser( + "~/auto-package-testing/jenkins/boottest-britney") os.makedirs(os.path.dirname(script_path)) with open(script_path, 'w') as f: f.write('''#!%(py)s