Files
discordeno/tests/guilds/members/dms.test.ts
2022-05-31 15:12:44 +00:00

13 lines
447 B
TypeScript

import { assertExists } from "../../deps.ts";
import { loadBot } from "../../mod.ts";
Deno.test("[member] get dm channel and send a message", async () => {
const bot = loadBot();
// Itoh Alt ID
const channel = await bot.helpers.getDmChannel(750661528360845322n);
assertExists(channel?.id);
const message = await bot.helpers.sendMessage(channel.id, { content: "https://i.imgur.com/doG55NR.png" });
assertExists(message?.content);
});