Now that we have added a post-processing step for adding truth value testing to

those lldb objects which implement the IsValid() method, let's change the rest of
the test suite to use the more compact truth value testing pattern (the Python way).

llvm-svn: 131970
This commit is contained in:
Johnny Chen
2011-05-24 18:22:45 +00:00
parent 97019c709d
commit 4ebd019b97
27 changed files with 137 additions and 137 deletions

View File

@@ -35,11 +35,11 @@ class CommandInterpreterAPICase(TestBase):
# Create a target by the debugger.
target = self.dbg.CreateTarget(exe)
self.assertTrue(target.IsValid(), VALID_TARGET)
self.assertTrue(target, VALID_TARGET)
# Retrieve the associated command interpreter from our debugger.
ci = self.dbg.GetCommandInterpreter()
self.assertTrue(ci.IsValid(), VALID_COMMAND_INTERPRETER)
self.assertTrue(ci, VALID_COMMAND_INTERPRETER)
# Exercise some APIs....
@@ -61,7 +61,7 @@ class CommandInterpreterAPICase(TestBase):
# Assigning to self.process so it gets cleaned up during test tear down.
self.process = ci.GetProcess()
self.assertTrue(self.process.IsValid())
self.assertTrue(self.process)
import lldbutil
if self.process.GetState() != lldb.eStateStopped: