lmi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi-commits] [lmi] valyuta/002 3d21745 3/8: Fix unit tests


From: Greg Chicares
Subject: [lmi-commits] [lmi] valyuta/002 3d21745 3/8: Fix unit tests
Date: Mon, 5 Oct 2020 19:57:18 -0400 (EDT)

branch: valyuta/002
commit 3d21745a094d707986a166edd08a8ac7413fa28a
Author: Gregory W. Chicares <gchicares@sbcglobal.net>
Commit: Gregory W. Chicares <gchicares@sbcglobal.net>

    Fix unit tests
    
    Broken by commit 5fb74f1b1ac of 20200920T2245Z.
---
 currency_test.cpp | 2 +-
 round_to_test.cpp | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/currency_test.cpp b/currency_test.cpp
index 3c3ebbf..01182fd 100644
--- a/currency_test.cpp
+++ b/currency_test.cpp
@@ -131,7 +131,7 @@ std::cout << "int4: " << big_int4 << std::endl;
     b2 += b0;
     b2 += b1;
     currency b3 = b0 + b1;
-    BOOST_TEST_EQUAL(b2.m(), b3.m());
+    BOOST_TEST_EQUAL(b2.cents(), b3.cents());
     BOOST_TEST_EQUAL(b2, b3);
 }
 
diff --git a/round_to_test.cpp b/round_to_test.cpp
index 0fa70b6..da411e9 100644
--- a/round_to_test.cpp
+++ b/round_to_test.cpp
@@ -547,7 +547,7 @@ int test_main(int, char*[])
     // Test rounding double to currency.
     currency c = round0.c(1.61803398875);
     BOOST_TEST((1.62 - c.d()) < 1e-14);
-    BOOST_TEST_EQUAL(162, c.m());
+    BOOST_TEST_EQUAL(162, c.cents());
 //  c *= 0.61803398875;
 //  BOOST_TEST_EQUAL(1, c);
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]