Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
f0cii committed Apr 24, 2020
1 parent 750b9a4 commit 7d79bcd
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
16 changes: 16 additions & 0 deletions client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,22 @@ func TestClient_GetPosition(t *testing.T) {
t.Logf("%#v", result)
}

func TestClient_BuyMarket(t *testing.T) {
client := newClient()
params := &models.BuyParams{
InstrumentName: "BTC-PERPETUAL",
Amount: 10,
Price: 0,
Type: "market",
}
result, err := client.Buy(params)
if err != nil {
t.Error(err)
return
}
t.Logf("%#v", result)
}

func TestClient_Buy(t *testing.T) {
client := newClient()
params := &models.BuyParams{
Expand Down
1 change: 1 addition & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ github.com/sourcegraph/jsonrpc2 v0.0.0-20191222043438-96c4efab7ee2/go.mod h1:Zaf
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
github.com/stretchr/testify v1.5.1 h1:nOGnQDM7FYENwehXlg/kFVnos3rEvtKTjRvOWSzb6H4=
github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA=
github.com/sumorf/deribit-api v0.0.0-20191024014042-05ddd1385bf2/go.mod h1:5bdqVP0ePpCpfy1whSPwvUTwwWyXBjLjD87s3iq3QK4=
go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
Expand Down

0 comments on commit 7d79bcd

Please sign in to comment.