mirror of
https://github.com/shopspring/decimal.git
synced 2024-11-22 20:40:48 +01:00
gofmt -s decimal_test.go
This commit is contained in:
parent
d48ced5acf
commit
4ec03b4267
1 changed files with 17 additions and 17 deletions
|
@ -165,10 +165,10 @@ func TestNewFromStringDeepEquals(t *testing.T) {
|
|||
expected bool
|
||||
}
|
||||
tests := []StrCmp{
|
||||
StrCmp{"1", "1", true},
|
||||
StrCmp{"10", "10.0", true},
|
||||
StrCmp{"1.1", "1.10", true},
|
||||
StrCmp{"1.001", "1.01", false},
|
||||
{"1", "1", true},
|
||||
{"10", "10.0", true},
|
||||
{"1.1", "1.10", true},
|
||||
{"1.001", "1.01", false},
|
||||
}
|
||||
|
||||
for _, cmp := range tests {
|
||||
|
@ -741,19 +741,19 @@ func TestDecimal_QuoRem(t *testing.T) {
|
|||
r string
|
||||
}
|
||||
cases := []Inp4{
|
||||
Inp4{"10", "1", 0, "10", "0"},
|
||||
Inp4{"1", "10", 0, "0", "1"},
|
||||
Inp4{"1", "4", 2, "0.25", "0"},
|
||||
Inp4{"1", "8", 2, "0.12", "0.04"},
|
||||
Inp4{"10", "3", 1, "3.3", "0.1"},
|
||||
Inp4{"100", "3", 1, "33.3", "0.1"},
|
||||
Inp4{"1000", "10", -3, "0", "1000"},
|
||||
Inp4{"1e-3", "2e-5", 0, "50", "0"},
|
||||
Inp4{"1e-3", "2e-3", 1, "0.5", "0"},
|
||||
Inp4{"4e-3", "0.8", 4, "5e-3", "0"},
|
||||
Inp4{"4.1e-3", "0.8", 3, "5e-3", "1e-4"},
|
||||
Inp4{"-4", "-3", 0, "1", "-1"},
|
||||
Inp4{"-4", "3", 0, "-1", "-1"},
|
||||
{"10", "1", 0, "10", "0"},
|
||||
{"1", "10", 0, "0", "1"},
|
||||
{"1", "4", 2, "0.25", "0"},
|
||||
{"1", "8", 2, "0.12", "0.04"},
|
||||
{"10", "3", 1, "3.3", "0.1"},
|
||||
{"100", "3", 1, "33.3", "0.1"},
|
||||
{"1000", "10", -3, "0", "1000"},
|
||||
{"1e-3", "2e-5", 0, "50", "0"},
|
||||
{"1e-3", "2e-3", 1, "0.5", "0"},
|
||||
{"4e-3", "0.8", 4, "5e-3", "0"},
|
||||
{"4.1e-3", "0.8", 3, "5e-3", "1e-4"},
|
||||
{"-4", "-3", 0, "1", "-1"},
|
||||
{"-4", "3", 0, "-1", "-1"},
|
||||
}
|
||||
|
||||
for _, inp4 := range cases {
|
||||
|
|
Loading…
Reference in a new issue