Index: test/lib/TestCommon.py |
=================================================================== |
--- test/lib/TestCommon.py (revision 1384) |
+++ test/lib/TestCommon.py (working copy) |
@@ -189,19 +189,16 @@ |
missing.append(f) |
return existing, missing |
-if os.name == 'posix': |
Nico
2012/05/17 20:31:57
The two branches looked identical to me, so I got
|
- def _failed(self, status = 0): |
- if self.status is None or status is None: |
- return None |
- return _status(self) != status |
- def _status(self): |
- return self.status |
-elif os.name == 'nt': |
- def _failed(self, status = 0): |
- return not (self.status is None or status is None) and \ |
- self.status != status |
- def _status(self): |
- return self.status |
+def _failed(self, status = 0): |
+ if self.status is None or status is None: |
+ return None |
+ try: |
+ return _status(self) not in status |
Mark Mentovai
2012/05/17 21:08:58
OK to the reorganization, but could you be consist
Nico
2012/05/17 21:29:36
Done. Huh, looks like this file doesn't use google
|
+ except TypeError: |
+ # status wasn't an iterable |
+ return _status(self) != status |
+def _status(self): |
+ return self.status |
class TestCommon(TestCmd): |