Author: Petr Hosek Date: 2021-06-08T16:11:06-07:00 New Revision: cf3e126e6449255ef183df71f5c54020d7a87ee5
URL: https://github.com/llvm/llvm-project/commit/cf3e126e6449255ef183df71f5c54020d7a87ee5 DIFF: https://github.com/llvm/llvm-project/commit/cf3e126e6449255ef183df71f5c54020d7a87ee5.diff LOG: [libcxx] Make the GDB pretty printer test less strict This is a workaround for PR48937. GDB can sometimes print additional warnings which currently fails the test. Use re.search instead of re.match to ignore this additional output. Differential Revision: https://reviews.llvm.org/D99532 (cherry picked from commit 9ac988f6a80aa1dd25594a8b4c86c0380ac99466) Added: Modified: libcxx/test/libcxx/gdb/gdb_pretty_printer_test.py Removed: ################################################################################ diff --git a/libcxx/test/libcxx/gdb/gdb_pretty_printer_test.py b/libcxx/test/libcxx/gdb/gdb_pretty_printer_test.py index af473c48ea9ab..19e9a4a793bf8 100644 --- a/libcxx/test/libcxx/gdb/gdb_pretty_printer_test.py +++ b/libcxx/test/libcxx/gdb/gdb_pretty_printer_test.py @@ -49,7 +49,7 @@ def invoke(self, arg, from_tty): expectation_val = compare_frame.read_var("expectation") check_literal = expectation_val.string(encoding="utf-8") if "PrettyPrintToRegex" in compare_frame.name(): - test_fails = not re.match(check_literal, value) + test_fails = not re.search(check_literal, value) else: test_fails = value != check_literal _______________________________________________ llvm-branch-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits
