From dca3e301410be4aee5a7895a1c2c1bbf90f3d03b Mon Sep 17 00:00:00 2001 From: xiaoyong931011 <15274802129@163.com> Date: Wed, 16 Mar 2022 15:21:36 +0800 Subject: [PATCH] 20222223 --- src/test/java/com/xcong/excoin/OtcTest.java | 13 ++++++++----- 1 files changed, 8 insertions(+), 5 deletions(-) diff --git a/src/test/java/com/xcong/excoin/OtcTest.java b/src/test/java/com/xcong/excoin/OtcTest.java index 2f2a67e..aaa786e 100644 --- a/src/test/java/com/xcong/excoin/OtcTest.java +++ b/src/test/java/com/xcong/excoin/OtcTest.java @@ -107,17 +107,20 @@ @Test public void bigdecimalTest() { BigDecimal one = BigDecimal.valueOf(6.39); - BigDecimal two = BigDecimal.valueOf(15.64); + BigDecimal two = BigDecimal.valueOf(3129.860025); + BigDecimal three = BigDecimal.valueOf(19999.80); - System.out.println(one.multiply(two)); + BigDecimal cny = one.multiply(two).setScale(2, BigDecimal.ROUND_DOWN); + BigDecimal usdt = three.divide(one, 2, BigDecimal.ROUND_DOWN); + System.out.println(cny.compareTo(three) != 0 && usdt.compareTo(two) != 0); } - @Autowired - private OtcConsumer otcConsumer; +// @Autowired +// private OtcConsumer otcConsumer; @Test public void returnMoneyTest() { // otcConsumer.orderReturn("20210605446780002"); - otcProducter.sendOrderReturn("20210605446780002"); +// otcProducter.sendOrderReturn("20210605446780002"); } } -- Gitblit v1.9.1