feat: add package creation and clone validation
This commit is contained in:
18
internal/repository/paket_create_test.go
Normal file
18
internal/repository/paket_create_test.go
Normal file
@@ -0,0 +1,18 @@
|
||||
package repository
|
||||
|
||||
import "testing"
|
||||
|
||||
func TestDecimalText(t *testing.T) {
|
||||
for _, test := range []struct {
|
||||
cents int64
|
||||
want string
|
||||
}{
|
||||
{cents: 13000000, want: "130000.00"},
|
||||
{cents: 1, want: "0.01"},
|
||||
{cents: 0, want: "0.00"},
|
||||
} {
|
||||
if got := decimalText(test.cents); got != test.want {
|
||||
t.Fatalf("decimalText(%d)=%q want=%q", test.cents, got, test.want)
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user