[Lldb-commits] [lldb] r124589 - /lldb/trunk/test/settings/TestSettings.py
Caroline Tice
ctice at apple.com
Mon Jan 31 10:18:54 PST 2011
Author: ctice
Date: Mon Jan 31 12:18:54 2011
New Revision: 124589
URL: http://llvm.org/viewvc/llvm-project?rev=124589&view=rev
Log:
Add a few more settings tests.
Modified:
lldb/trunk/test/settings/TestSettings.py
Modified: lldb/trunk/test/settings/TestSettings.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/settings/TestSettings.py?rev=124589&r1=124588&r2=124589&view=diff
==============================================================================
--- lldb/trunk/test/settings/TestSettings.py (original)
+++ lldb/trunk/test/settings/TestSettings.py Mon Jan 31 12:18:54 2011
@@ -189,6 +189,37 @@
self.expect(output, exe=False,
startstr = "This message should go to standard out.")
+ def test_print_dictionary_setting(self):
+ self.runCmd ("settings set -r target.process.env-vars")
+ self.runCmd ("settings set target.process.env-vars [\"MY_VAR\"]=some-value")
+ self.expect ("settings show target.process.env-vars",
+ substrs = [ "'MY_VAR=some-value'" ])
+ self.runCmd ("settings set -r target.process.env-vars")
+
+ def test_print_array_setting(self):
+ self.runCmd ("settings set -r target.process.run-args")
+ self.runCmd ("settings set target.process.run-args gobbledy-gook")
+ self.expect ("settings show target.process.run-args",
+ substrs = [ "[0]: 'gobbledy-gook'" ])
+ self.runCmd ("settings set -r target.process.run-args")
+
+ def test_settings_with_quotes (self):
+ self.runCmd ("settings set -r target.process.run-args")
+ self.runCmd ("settings set target.process.run-args a b c")
+ self.expect ("settings show target.process.run-args",
+ substrs = [ "[0]: 'a'",
+ "[1]: 'b'",
+ "[2]: 'c'" ])
+ self.runCmd ("settings set target.process.run-args 'a b c'")
+ self.expect ("settings show target.process.run-args",
+ substrs = [ "[0]: 'a b c'" ])
+ self.runCmd ("settings set -r target.process.run-args")
+ self.runCmd ("settings set -r target.process.env-vars")
+ self.runCmd ("settings set target.process.env-vars [\"MY_FILE\"]='this is a file name with spaces.txt'")
+ self.expect ("settings show target.process.env-vars",
+ substrs = [ "'MY_FILE=this is a file name with spaces.txt'" ])
+ self.runCmd ("settings set -r target.process.env-vars")
+
if __name__ == '__main__':
import atexit
More information about the lldb-commits
mailing list