Skip to content

Commit 9773ce2

Browse files
Update test_cstring.c
1 parent 90f56b3 commit 9773ce2

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

code/tests/cases/test_cstring.c

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -778,11 +778,11 @@ FOSSIL_TEST(c_test_cstring_number_to_words) {
778778
FOSSIL_TEST(c_test_cstring_string_to_money) {
779779
double value;
780780

781-
ASSUME_ITS_EQUAL_F64(0, fossil_io_cstring_string_to_money("$1,234.56", &value), 0.0);
782-
ASSUME_ITS_EQUAL_F64(value, 1234.56, 0.001);
781+
ASSUME_ITS_EQUAL_F32(0, fossil_io_cstring_string_to_money("$1,234.56", &value), 0.0);
782+
ASSUME_ITS_EQUAL_F32(value, 1234.56, 0.001);
783783

784-
ASSUME_ITS_EQUAL_F64(0, fossil_io_cstring_string_to_money("-$42.50", &value), 0.0);
785-
ASSUME_ITS_EQUAL_F64(value, -42.50, 0.001);
784+
ASSUME_ITS_EQUAL_F32(0, fossil_io_cstring_string_to_money("-$42.50", &value), 0.0);
785+
ASSUME_ITS_EQUAL_F32(value, -42.50, 0.001);
786786

787787
// Invalid string
788788
ASSUME_ITS_TRUE(fossil_io_cstring_string_to_money("foobar", &value) != 0);
@@ -792,14 +792,14 @@ FOSSIL_TEST(c_test_cstring_string_to_money) {
792792
FOSSIL_TEST(c_test_cstring_string_to_money_currency) {
793793
double value;
794794

795-
ASSUME_ITS_EQUAL_F64(0, fossil_io_cstring_string_to_money_currency("$1,234.56", &value), 0.0);
796-
ASSUME_ITS_EQUAL_F64(value, 1234.56, 0.001);
795+
ASSUME_ITS_EQUAL_F32(0, fossil_io_cstring_string_to_money_currency("$1,234.56", &value), 0.0);
796+
ASSUME_ITS_EQUAL_F32(value, 1234.56, 0.001);
797797

798-
ASSUME_ITS_EQUAL_F64(0, fossil_io_cstring_string_to_money_currency("€987.65", &value), 0.0);
799-
ASSUME_ITS_EQUAL_F64(value, 987.65, 0.001);
798+
ASSUME_ITS_EQUAL_F32(0, fossil_io_cstring_string_to_money_currency("€987.65", &value), 0.0);
799+
ASSUME_ITS_EQUAL_F32(value, 987.65, 0.001);
800800

801-
ASSUME_ITS_EQUAL_F64(0, fossil_io_cstring_string_to_money_currency("-$42.50", &value), 0.0);
802-
ASSUME_ITS_EQUAL_F64(value, -42.50, 0.001);
801+
ASSUME_ITS_EQUAL_F32(0, fossil_io_cstring_string_to_money_currency("-$42.50", &value), 0.0);
802+
ASSUME_ITS_EQUAL_F32(value, -42.50, 0.001);
803803

804804
// Invalid format
805805
ASSUME_ITS_TRUE(fossil_io_cstring_string_to_money_currency("foobar", &value) != 0);

0 commit comments

Comments
 (0)