mirror of
https://github.com/discordeno/discordeno.git
synced 2026-05-29 23:10:07 +00:00
* Create deno.json * run format * run format * ci: only check formatting * f * Update settings.json * Update settings.json
25 lines
712 B
TypeScript
25 lines
712 B
TypeScript
import { assertExists } from "../deps.ts";
|
|
import { bot } from "../mod.ts";
|
|
import { ActivityTypes } from "../../src/types/activity/activityTypes.ts";
|
|
import { delayUntil } from "../utils.ts";
|
|
|
|
Deno.test("[misc] edit the bot's status", async function () {
|
|
bot.events.presenceUpdate = function (_bot, presense, _oldPresense) {
|
|
console.log("in pu");
|
|
console.log("in pu");
|
|
assertExists(presense);
|
|
};
|
|
|
|
bot.events.botUpdate = function (bot, user) {
|
|
console.log("in bu");
|
|
console.log("in bu");
|
|
};
|
|
|
|
bot.helpers.editBotStatus({
|
|
status: "dnd",
|
|
activities: [{ name: "lts20050703", type: ActivityTypes.Game, createdAt: Date.now() }],
|
|
});
|
|
|
|
await delayUntil(10000, () => false);
|
|
});
|