mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-05-29 15:10:37 +00:00
stream/websocket: Consolidate fields by using exchange config pointer (#809)
* stream: add exchange config pointer to setup WebsocketSetup struct to reduce and consolidate setting of variables. * config: reduce stutter * config: reduce minor stutter * glorious: nits addr. * Update exchanges/stream/websocket.go Co-authored-by: Scott <gloriousCode@users.noreply.github.com> * websocket: implement fix * engine/helpers: fix test * exchanges: fix after merge issues * exchange_template: fix output Co-authored-by: Scott <gloriousCode@users.noreply.github.com>
This commit is contained in:
@@ -215,7 +215,7 @@ func TestUnloadExchange(t *testing.T) {
|
||||
exch.SetEnabled(true)
|
||||
em.Add(exch)
|
||||
e := &Engine{ExchangeManager: em,
|
||||
Config: &config.Config{Exchanges: []config.ExchangeConfig{{Name: testExchange}}},
|
||||
Config: &config.Config{Exchanges: []config.Exchange{{Name: testExchange}}},
|
||||
}
|
||||
err = e.UnloadExchange("asdf")
|
||||
if !errors.Is(err, config.ErrExchangeNotFound) {
|
||||
@@ -240,7 +240,7 @@ func TestDryRunParamInteraction(t *testing.T) {
|
||||
ExchangeManager: SetupExchangeManager(),
|
||||
Settings: Settings{},
|
||||
Config: &config.Config{
|
||||
Exchanges: []config.ExchangeConfig{
|
||||
Exchanges: []config.Exchange{
|
||||
{
|
||||
Name: testExchange,
|
||||
WebsocketTrafficTimeout: time.Second,
|
||||
|
||||
Reference in New Issue
Block a user