mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-16 11:28:15 +00:00
refactor
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { Bot } from "../../src/bot.ts";
|
||||
import { assertExists } from "../deps.ts";
|
||||
import { delayUntil } from "../utils.ts";
|
||||
import { Bot } from "../../../src/bot.ts";
|
||||
import { assertExists } from "../../deps.ts";
|
||||
import { delayUntil } from "../../utils.ts";
|
||||
|
||||
async function ifItFailsBlameWolf(bot: Bot, channelId: bigint, reason?: string) {
|
||||
const message = await bot.helpers.sendMessage(channelId, "Hello World!");
|
||||
+1
-9
@@ -1,9 +1 @@
|
||||
import { snowflakeToBigint } from "../mod.ts";
|
||||
import { assertEquals } from "./deps.ts";
|
||||
|
||||
Deno.test("[Local Test] - snowflakeToBigint ", async (t) => {
|
||||
const text = "130136895395987456";
|
||||
const big = 130136895395987456n;
|
||||
|
||||
assertEquals(big, snowflakeToBigint(text));
|
||||
});
|
||||
import "./local/snowflake.ts";
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
import { snowflakeToBigint } from "../../src/util/bigint.ts";
|
||||
import { assertEquals } from "../deps.ts";
|
||||
|
||||
Deno.test("[Local Test] - snowflakeToBigint ", async (t) => {
|
||||
const text = "130136895395987456";
|
||||
const big = 130136895395987456n;
|
||||
|
||||
assertEquals(big, snowflakeToBigint(text));
|
||||
});
|
||||
+1
-2
@@ -1,8 +1,7 @@
|
||||
import { TOKEN } from "../configs.ts";
|
||||
import { createBot, createEventHandlers, DiscordChannelTypes, startBot, stopBot } from "../mod.ts";
|
||||
import { assertEquals, assertExists } from "./deps.ts";
|
||||
import { deleteMessageWithReasonTest } from "./messages/deleteMessage.ts";
|
||||
import { deleteMessageWithoutReasonTest } from "./messages/deleteMessage.ts";
|
||||
import { deleteMessageWithReasonTest, deleteMessageWithoutReasonTest } from "./helpers/messages/deleteMessage.ts";
|
||||
import { delayUntil } from "./utils.ts";
|
||||
|
||||
// CONDUCT LOCAL TESTS FIRST BEFORE RUNNING API TEST
|
||||
|
||||
Reference in New Issue
Block a user