parent
e3724e56fe
commit
56bdfc6a73
@ -1,13 +0,0 @@
|
||||
package godecimal
|
||||
|
||||
import (
|
||||
"reflect"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestCalculation(t *testing.T) {
|
||||
t.Log("加:", Float64Add(10, 3), reflect.TypeOf(Float64Add(10, 3)))
|
||||
t.Log("减", Float64Sub(10, 3), reflect.TypeOf(Float64Sub(10, 3)))
|
||||
t.Log("乘:", Float64Mul(10, 3), reflect.TypeOf(Float64Mul(10, 3)))
|
||||
t.Log("除:", Float64Quo(10, 3), reflect.TypeOf(Float64Quo(10, 3)))
|
||||
}
|
@ -1,26 +0,0 @@
|
||||
package godecimal
|
||||
|
||||
import "testing"
|
||||
|
||||
func TestMath(t *testing.T) {
|
||||
t.Log(Abs(111))
|
||||
t.Log(Abs(-111))
|
||||
|
||||
t.Log(Floor(3.4))
|
||||
t.Log(Floor(3.5))
|
||||
|
||||
t.Log(Ceil(3.4))
|
||||
t.Log(Ceil(3.5))
|
||||
|
||||
t.Log(Round(3.4))
|
||||
t.Log(Round(3.5))
|
||||
|
||||
t.Log(RoundPoint(3.4))
|
||||
t.Log(RoundPoint(3.5))
|
||||
t.Log(RoundPoint(3.14))
|
||||
t.Log(RoundPoint(3.14159))
|
||||
|
||||
t.Log(Max(4, 3))
|
||||
|
||||
t.Log(Min(4, 3))
|
||||
}
|
@ -1,3 +1,3 @@
|
||||
package godecimal
|
||||
|
||||
const Version = "1.0.6"
|
||||
const Version = "1.0.7"
|
||||
|
@ -1,7 +0,0 @@
|
||||
package godecimal
|
||||
|
||||
import "testing"
|
||||
|
||||
func TestVersion(t *testing.T) {
|
||||
t.Log(Version)
|
||||
}
|
Loading…
Reference in new issue