diff options
author | Martin Pitt <martin.pitt@ubuntu.com> | 2014-09-02 17:19:08 +0200 |
---|---|---|
committer | Martin Pitt <martin.pitt@ubuntu.com> | 2014-09-02 17:19:08 +0200 |
commit | 01ab81233f1e85afe8c3078d6a8d894d627e42fb (patch) | |
tree | 3073e38d04aadefc99239937c24c5c73e8632fa5 /src | |
parent | e5bd3e80f3239d4d52b52b91e73007f12f60d312 (diff) | |
download | upower-01ab81233f1e85afe8c3078d6a8d894d627e42fb.tar.gz |
Linux integration tests: Fix error handling for Python 3.4
Python 3.4 changed the TestCase._outcome semantics, adjust accordingly.
Diffstat (limited to 'src')
-rwxr-xr-x | src/linux/integration-test | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/linux/integration-test b/src/linux/integration-test index f99fe1f..1d28319 100755 --- a/src/linux/integration-test +++ b/src/linux/integration-test @@ -109,7 +109,8 @@ class Tests(unittest.TestCase): self.stop_daemon() # on failures, print daemon log - if not self._outcomeForDoCleanups.success and self.log: + errors = [x[1] for x in self._outcome.errors if x[1]] + if errors and self.log: with open(self.log.name) as f: sys.stderr.write('\n-------------- daemon log: ----------------\n') sys.stderr.write(f.read()) |