mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-19 13:03:31 +01:00
refactor(WebSocketManager)!: remove deprecated rest option (#10998)
BREAKING CHANGE: The `rest` option in the `WebSocketManager` constructor has been removed. Pass a `fetchGatewayInformation` function instead.
This commit is contained in:
12
packages/ws/__tests__/gateway.mock.ts
Normal file
12
packages/ws/__tests__/gateway.mock.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import type { RESTGetAPIGatewayBotResult } from 'discord-api-types/v10';
|
||||
|
||||
export const mockGatewayInformation: RESTGetAPIGatewayBotResult = {
|
||||
shards: 1,
|
||||
session_start_limit: {
|
||||
max_concurrency: 3,
|
||||
reset_after: 60,
|
||||
remaining: 3,
|
||||
total: 3,
|
||||
},
|
||||
url: 'wss://gateway.discord.gg',
|
||||
};
|
||||
Reference in New Issue
Block a user