From fab0b1b7e0ff0321be67ea22e119d760551a2588 Mon Sep 17 00:00:00 2001 From: Nathan <148575555+nathan-artie@users.noreply.github.com> Date: Wed, 26 Jun 2024 11:33:01 -0700 Subject: [PATCH] Revert --- lib/typing/values/string_test.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/typing/values/string_test.go b/lib/typing/values/string_test.go index af33186d3..945a8f756 100644 --- a/lib/typing/values/string_test.go +++ b/lib/typing/values/string_test.go @@ -4,10 +4,10 @@ import ( "testing" "time" - "github.com/cockroachdb/apd/v3" "github.com/stretchr/testify/assert" "github.com/artie-labs/transfer/lib/config/constants" + "github.com/artie-labs/transfer/lib/numbers" "github.com/artie-labs/transfer/lib/ptr" "github.com/artie-labs/transfer/lib/typing" "github.com/artie-labs/transfer/lib/typing/columns" @@ -123,9 +123,7 @@ func TestToString(t *testing.T) { assert.Equal(t, "123.45", val) // Decimals - _decimal, _, err := apd.NewFromString("585692791691858.25") - assert.NoError(t, err) - value := decimal.NewDecimal(ptr.ToInt(38), _decimal) + value := decimal.NewDecimal(ptr.ToInt(38), numbers.MustParseDecimal("585692791691858.25")) val, err = ToString(value, columns.Column{KindDetails: typing.EDecimal}, nil) assert.NoError(t, err) assert.Equal(t, "585692791691858.25", val)