mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-04-19 03:01:48 +08:00
fix bug
This commit is contained in:
parent
2d2cb4590d
commit
38dd205b56
@ -24,6 +24,7 @@
|
||||
* 【core 】 修复NamingCase中转换下划线字母+数字转换问题(issue#2070@Github)
|
||||
* 【core 】 修复split空判断不一致问题(pr#496@Gitee)
|
||||
* 【crypto 】 修复SM2.getDHex()前导0丢失,然后导致获取密钥错误(pr#2073@Github)
|
||||
* 【core 】 修复关于Calculator.conversion()方法EmptyStackException的bug(pr#2076@Github)
|
||||
|
||||
-------------------------------------------------------------------------------------------------------------
|
||||
# 5.7.18 (2021-12-25)
|
||||
|
@ -1,7 +1,6 @@
|
||||
package cn.hutool.core.math;
|
||||
|
||||
import org.junit.Assert;
|
||||
import org.junit.Ignore;
|
||||
import org.junit.Test;
|
||||
|
||||
public class CalculatorTest {
|
||||
@ -42,4 +41,11 @@ public class CalculatorTest {
|
||||
final double conversion = Calculator.conversion("-((2.12-2) * 100)");
|
||||
Assert.assertEquals(-1D * (2.12 - 2) * 100, conversion, 2);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void conversationTest7() {
|
||||
//https://gitee.com/dromara/hutool/issues/I4KONB
|
||||
final double conversion = Calculator.conversion("((-2395+0) * 0.3+140.24+35+90)/30");
|
||||
Assert.assertEquals(-15.11, conversion, 2);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user