Skip to content

Commit

Permalink
fix account test
Browse files Browse the repository at this point in the history
  • Loading branch information
c9s committed Dec 16, 2024
1 parent 7122285 commit cf765d6
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions pkg/service/account_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import (
"github.com/jmoiron/sqlx"
"github.com/stretchr/testify/assert"

"github.com/c9s/bbgo/pkg/asset"
"github.com/c9s/bbgo/pkg/fixedpoint"
"github.com/c9s/bbgo/pkg/types"
"github.com/c9s/bbgo/pkg/types/asset"
)

func TestAccountService(t *testing.T) {
Expand All @@ -26,16 +26,16 @@ func TestAccountService(t *testing.T) {
t1 := time.Now()
err = service.InsertAsset(t1, "binance", types.ExchangeBinance, "main", false, false, "", asset.Map{
"BTC": asset.Asset{
Currency: "BTC",
Total: fixedpoint.MustNewFromString("1.0"),
InUSD: fixedpoint.MustNewFromString("10.0"),
InBTC: fixedpoint.MustNewFromString("0.0001"),
Time: t1,
Locked: fixedpoint.MustNewFromString("0"),
Available: fixedpoint.MustNewFromString("1.0"),
Borrowed: fixedpoint.MustNewFromString("0"),
NetAsset: fixedpoint.MustNewFromString("1"),
PriceInUSD: fixedpoint.MustNewFromString("44870"),
Currency: "BTC",
Total: fixedpoint.MustNewFromString("1.0"),
NetAssetInUSD: fixedpoint.MustNewFromString("10.0"),
NetAssetInBTC: fixedpoint.MustNewFromString("0.0001"),
Time: t1,
Locked: fixedpoint.MustNewFromString("0"),
Available: fixedpoint.MustNewFromString("1.0"),
Borrowed: fixedpoint.MustNewFromString("0"),
NetAsset: fixedpoint.MustNewFromString("1"),
PriceInUSD: fixedpoint.MustNewFromString("44870"),
},
})
assert.NoError(t, err)
Expand Down

0 comments on commit cf765d6

Please sign in to comment.