diff --git a/git_upstream/lib/importupstream.py b/git_upstream/lib/importupstream.py index a99b114..6058269 100644 --- a/git_upstream/lib/importupstream.py +++ b/git_upstream/lib/importupstream.py @@ -237,7 +237,7 @@ class ImportUpstream(LogDedentMixin, GitMixin): ancestors.add(root) # look for merge commits that are not part of ancestry path - for idx in xrange(counter - 1, -1, -1): + for idx in range(counter - 1, -1, -1): commit = sequence[idx] # if there is only one parent, no need to check the others if len(commit.parents) < 2: diff --git a/git_upstream/tests/commands/import/test_import.py b/git_upstream/tests/commands/import/test_import.py index cc42c38..3402bda 100644 --- a/git_upstream/tests/commands/import/test_import.py +++ b/git_upstream/tests/commands/import/test_import.py @@ -67,6 +67,10 @@ class TestImportCommand(TestWithScenarios, BaseTestCase): self.assertThat(self.logger.output, Contains("Starting execution of import command")) + self.assertThat( + self.logger.output, + Not(Contains("Exception occurred during linearisation"))) + # perform sanity checks on results self._check_tree_state()