diff --git a/src/models/gateway.ts b/src/models/gateway.ts index 4885bf4..09fbffe 100644 --- a/src/models/gateway.ts +++ b/src/models/gateway.ts @@ -180,6 +180,10 @@ class Gateway { this.websocket.onclose = this.onclose.bind(this) this.websocket.onerror = this.onerror.bind(this) } + + close () { + this.websocket.close(1000) + } } export { Gateway } diff --git a/src/test/config.ts.sample b/src/test/config.ts.sample index 3f6b2f9..44a8029 100644 --- a/src/test/config.ts.sample +++ b/src/test/config.ts.sample @@ -1 +1,2 @@ const TOKEN = '' +export { TOKEN }