In order to get rid of extra line feeds in exception message.
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
except Exception as excobj:
raise GitRepositoryError("Error running git %s: %s" % (command, excobj))
if ret:
- raise GitRepositoryError("Error running git %s: %s" % (command, stderr))
+ raise GitRepositoryError("Error running git %s: %s" %
+ (command, stderr.strip()))
def _cmd_has_feature(self, command, feature):
with open('my2.patch', 'w') as patch_file:
patch_file.write('-this-does\n+not-apply\n')
eq_(mock_pq(['import']), 1)
- self._check_log(-2, "("
+ self._check_log(-1, "("
"Aborting|"
"Please, commit your changes or stash them|"
"gbp:error: Import failed.* You have local changes"