Skip to content

Commit 64def31

Browse files
committed
tests: address remaining PR2201 review nits
1 parent 0232369 commit 64def31

File tree

2 files changed

+4
-10
lines changed

2 files changed

+4
-10
lines changed

exchanges/bybit/bybit_options_limits_test.go

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ func TestFetchTradablePairsFiltersNonTradingOptions(t *testing.T) {
2828
preLaunchInstrument := newOptionInstrumentInfo("BTC14MAR26-85000-C", "PreLaunch")
2929

3030
var queries []url.Values
31-
ex := newOptionsInstrumentInfoTestExchange(t, "BybitOptionsFetchTradablePairsTest", map[string][]optionInstrumentInfoResponse{
31+
ex := newInstrumentInfoTestExchange(t, "BybitOptionsFetchTradablePairsTest", cOption, map[string][]optionInstrumentInfoResponse{
3232
"BTC": {tradingInstrument, settlingInstrument, preLaunchInstrument},
3333
}, &queries)
3434

@@ -65,7 +65,7 @@ func TestUpdateOrderExecutionLimitsFiltersNonTradingOptions(t *testing.T) {
6565
closedInstrument := newOptionInstrumentInfo("BTC14MAR26-85000-C", "Closed")
6666

6767
var queries []url.Values
68-
ex := newOptionsInstrumentInfoTestExchange(t, "BybitOptionsUpdateLimitsTest", map[string][]optionInstrumentInfoResponse{
68+
ex := newInstrumentInfoTestExchange(t, "BybitOptionsUpdateLimitsTest", cOption, map[string][]optionInstrumentInfoResponse{
6969
"BTC": {tradingInstrument, settlingInstrument, closedInstrument},
7070
}, &queries)
7171

@@ -110,12 +110,6 @@ func TestUpdateOrderExecutionLimitsLeavesNonOptionsStatusHandlingUnchanged(t *te
110110
assert.Equal(t, "1000", queries[0].Get("limit"), "UpdateOrderExecutionLimits should request the expected page size")
111111
}
112112

113-
func newOptionsInstrumentInfoTestExchange(t *testing.T, name string, responses map[string][]optionInstrumentInfoResponse, queries *[]url.Values) *Exchange {
114-
t.Helper()
115-
116-
return newInstrumentInfoTestExchange(t, name, cOption, responses, queries)
117-
}
118-
119113
func newInstrumentInfoTestExchange(t *testing.T, name, category string, responses map[string][]optionInstrumentInfoResponse, queries *[]url.Values) *Exchange {
120114
t.Helper()
121115

exchanges/kucoin/kucoin_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2109,7 +2109,7 @@ func TestMergeRoundedOrderbookLevels(t *testing.T) {
21092109
},
21102110
},
21112111
{
2112-
name: "adjacentduplicatesmerge",
2112+
name: "adjacentDuplicatesMerge",
21132113
levels: []orderbook.Level{
21142114
{Price: 1e18, Amount: 0.00001405},
21152115
{Price: 1e18, Amount: 0.00064},
@@ -2121,7 +2121,7 @@ func TestMergeRoundedOrderbookLevels(t *testing.T) {
21212121
},
21222122
},
21232123
{
2124-
name: "nonadjacentduplicatesremainseparate",
2124+
name: "nonAdjacentDuplicatesRemainSeparate",
21252125
levels: []orderbook.Level{
21262126
{Price: 1.0, Amount: 1.0},
21272127
{Price: 2.0, Amount: 2.0},

0 commit comments

Comments
 (0)