summaryrefslogtreecommitdiff
path: root/libc/test/src/math/log_test.cpp
diff options
context:
space:
mode:
authorGuillaume Chatelet <gchatelet@google.com>2023-06-14 09:18:42 +0000
committerGuillaume Chatelet <gchatelet@google.com>2023-06-14 10:26:18 +0000
commit9a7b4c934893d6bc571e1ce8efab2127ae5f4e45 (patch)
treeeb3f10f5687916a4d79b4b4aeb6017aae767b000 /libc/test/src/math/log_test.cpp
parent595a74391daaff8daffa2f6e19274792d0074565 (diff)
[libc] Enable custom logging in LibcTest
This patch mimics the behavior of Google Test and allow users to log custom messages after all flavors of ASSERT_ / EXPECT_. Reviewed By: sivachandra, lntue Differential Revision: https://reviews.llvm.org/D152630
Diffstat (limited to 'libc/test/src/math/log_test.cpp')
-rw-r--r--libc/test/src/math/log_test.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/libc/test/src/math/log_test.cpp b/libc/test/src/math/log_test.cpp
index b1c9e205c4e9..230deffedddb 100644
--- a/libc/test/src/math/log_test.cpp
+++ b/libc/test/src/math/log_test.cpp
@@ -105,11 +105,11 @@ TEST(LlvmLibcLogTest, InDoubleRange) {
++count;
// ASSERT_MPFR_MATCH(mpfr::Operation::Log, x, result, 0.5);
- if (!EXPECT_MPFR_MATCH_ROUNDING_SILENTLY(mpfr::Operation::Log, x, result,
- 0.5, rounding_mode)) {
+ if (!TEST_MPFR_MATCH_ROUNDING_SILENTLY(mpfr::Operation::Log, x, result,
+ 0.5, rounding_mode)) {
++fails;
- while (!EXPECT_MPFR_MATCH_ROUNDING_SILENTLY(
- mpfr::Operation::Log, x, result, tol, rounding_mode)) {
+ while (!TEST_MPFR_MATCH_ROUNDING_SILENTLY(mpfr::Operation::Log, x,
+ result, tol, rounding_mode)) {
mx = x;
mr = result;
tol *= 2.0;