diff --git a/HookTest/build.py b/HookTest/build.py index e8e5d10..dd912a0 100644 --- a/HookTest/build.py +++ b/HookTest/build.py @@ -86,10 +86,11 @@ def run(self): if len(passing) == 0: return False, 'The manifest file is empty.\nStopping build.' self.remove_failing(self.repo_file_list(), passing) - to_zip = [x for x in glob('{}*'.format(self.dest))] - with tarfile.open("{}release.tar.gz".format(self.dest), mode="w:gz") as f: - for file in sorted(to_zip): - f.add(file) + # The following lines, while no longer needed here, could be useful for another build use case + #to_zip = [x for x in glob('{}*'.format(self.dest))] + #with tarfile.open("{}release.tar.gz".format(self.dest), mode="w:gz") as f: + # for file in sorted(to_zip): + # f.add(file) return True, 'Build successful.' diff --git a/tests/test_build.py b/tests/test_build.py index 5a2168f..d971052 100644 --- a/tests/test_build.py +++ b/tests/test_build.py @@ -209,12 +209,16 @@ def test_remove_failing_all(self): self.assertCountEqual(real, passing_files, "The files copied for the build do not match the expected value.") self.assertEqual(len(real), self.len_bad_repo, "The number of files copied for the build is incorrect.") + # This test is no longer needed for the Travis CI build. + # But I am keeping it here in case we might want to create a tar file for the build for another use case. + ''' def test_tar_contents(self): """ Compares the contents of the release.tar.gz file produced to the expected contents""" self.createTestDir('tests/100PercentRepo') HookTest.build.Travis(path=self.TESTDIR, dest=self.TESTDIR).run() with tarfile.open(self.TESTDIR + 'release.tar.gz', mode='r:gz') as f: self.assertCountEqual(f.getnames(), self.tar_contents) + ''' def test_base_class(self): """ Tests to make sure a build run on the base class returns and error"""