summaryrefslogtreecommitdiffstats
path: root/lldb/test/functionalities/data-formatter
diff options
context:
space:
mode:
authorChaoren Lin <chaorenl@google.com>2015-05-28 21:52:07 +0000
committerChaoren Lin <chaorenl@google.com>2015-05-28 21:52:07 +0000
commit842b214ac19e27bb41a54bbbc032a6e250651986 (patch)
tree8e33de9fbcabdf89ee5a78c359744283630c097b /lldb/test/functionalities/data-formatter
parentfa150d2aeecd8ab1d227e46b36b46be44a768abf (diff)
downloadbcm5719-llvm-842b214ac19e27bb41a54bbbc032a6e250651986.tar.gz
bcm5719-llvm-842b214ac19e27bb41a54bbbc032a6e250651986.zip
Simplify regex in TestDataFormatterUnordered.py for better readability.
Summary: Using `(match){3}` instead of `matchmatchmatch`. This is an update to D10078. Test Plan: no change in test behavior. Reviewers: clayborg, sivachandra Reviewed By: sivachandra Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D10094 llvm-svn: 238510
Diffstat (limited to 'lldb/test/functionalities/data-formatter')
-rw-r--r--lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/unordered/TestDataFormatterUnordered.py28
1 files changed, 22 insertions, 6 deletions
diff --git a/lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/unordered/TestDataFormatterUnordered.py b/lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/unordered/TestDataFormatterUnordered.py
index 2717c40b6ad..98554d9fb5e 100644
--- a/lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/unordered/TestDataFormatterUnordered.py
+++ b/lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/unordered/TestDataFormatterUnordered.py
@@ -61,12 +61,28 @@ class LibcxxUnorderedDataFormatterTestCase(TestBase):
self.expect('image list', substrs = self.getLibcPlusPlusLibs())
- self.look_for_content_and_continue("map", ['size=5 {', 'hello', 'world', 'this', 'is', 'me'])
- self.look_for_content_and_continue("mmap", ['size=6 {', 'first = 3', 'second = "this"', 'first = 2', 'second = "hello"'])
- self.look_for_content_and_continue("iset", ['size=5 {', '\[\d\] = 5', '\[\d\] = 3', '\[\d\] = 2'])
- self.look_for_content_and_continue("sset", ['size=5 {', '\[\d\] = "is"', '\[\d\] = "world"', '\[\d\] = "hello"'])
- self.look_for_content_and_continue("imset", ['size=6 {', '\[\d\] = 3(\\n|.)+\[\d\] = 3(\\n|.)+\[\d\] = 3', '\[\d\] = 2', '\[\d\] = 1'])
- self.look_for_content_and_continue("smset", ['size=5 {', '\[\d\] = "is"(\\n|.)+\[\d\] = "is"', '\[\d\] = "world"(\\n|.)+\[\d\] = "world"'])
+ self.look_for_content_and_continue(
+ "map", ['size=5 {', 'hello', 'world', 'this', 'is', 'me'])
+
+ self.look_for_content_and_continue(
+ "mmap", ['size=6 {', 'first = 3', 'second = "this"',
+ 'first = 2', 'second = "hello"'])
+
+ self.look_for_content_and_continue(
+ "iset", ['size=5 {', '\[\d\] = 5', '\[\d\] = 3', '\[\d\] = 2'])
+
+ self.look_for_content_and_continue(
+ "sset", ['size=5 {', '\[\d\] = "is"', '\[\d\] = "world"',
+ '\[\d\] = "hello"'])
+
+ self.look_for_content_and_continue(
+ "imset", ['size=6 {', '(\[\d\] = 3(\\n|.)+){3}',
+ '\[\d\] = 2', '\[\d\] = 1'])
+
+ self.look_for_content_and_continue(
+ "smset",
+ ['size=5 {', '(\[\d\] = "is"(\\n|.)+){2}',
+ '(\[\d\] = "world"(\\n|.)+){2}'])
if __name__ == '__main__':
import atexit
OpenPOWER on IntegriCloud