diff options
author | Lawrence D'Anna <lawrence_danna@apple.com> | 2019-10-22 04:00:37 +0000 |
---|---|---|
committer | Lawrence D'Anna <lawrence_danna@apple.com> | 2019-10-22 04:00:37 +0000 |
commit | d01083a850f577b85501a0902b52fd0930de72c7 (patch) | |
tree | b24509116e9d445a8a67f4ad60bd9d99e472c5c3 | |
parent | c302ff31dafa5b645899fcd2f2173d11f3264fc9 (diff) |
Looks like on windows googlemock regexes treat newlines differently
from on darwin. This patch fixes the regex in this test so it
will work on both.
Fixes: https://reviews.llvm.org/D69214
git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@375477 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp b/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp index b676b42da..7481482fd 100644 --- a/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp +++ b/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp @@ -805,13 +805,13 @@ main = foo PythonScript foo(script); - EXPECT_THAT_EXPECTED(foo(), - llvm::Failed<PythonException>(testing::Property( - &PythonException::ReadBacktrace, - testing::ContainsRegex("line 3, in foo..*" - "line 5, in bar.*" - "line 7, in baz.*" - "ZeroDivisionError")))); + EXPECT_THAT_EXPECTED( + foo(), llvm::Failed<PythonException>(testing::Property( + &PythonException::ReadBacktrace, + testing::AllOf(testing::ContainsRegex("line 3, in foo"), + testing::ContainsRegex("line 5, in bar"), + testing::ContainsRegex("line 7, in baz"), + testing::ContainsRegex("ZeroDivisionError"))))); static const char script2[] = R"( class MyError(Exception): |