mirror of
https://github.com/discordeno/discordeno.git
synced 2026-09-17 08:47:22 +00:00
* tests: fix stickers test * tests: fix stickers size must be 320x320 * deno fmt * Update README.md Co-authored-by: Skillz4Killz <23035000+Skillz4Killz@users.noreply.github.com>
27 lines
951 B
TypeScript
27 lines
951 B
TypeScript
import { assertEquals } from "../deps.ts";
|
|
import { loadBot } from "../mod.ts";
|
|
import { CACHED_COMMUNITY_GUILD_ID } from "../utils.ts";
|
|
|
|
Deno.test("[stickers] Edit guild sticker", async () => {
|
|
const bot = loadBot();
|
|
const createSticker = await bot.helpers.createGuildSticker(CACHED_COMMUNITY_GUILD_ID, {
|
|
name: "test",
|
|
description: "test",
|
|
tags: "test",
|
|
file: {
|
|
blob: await (await fetch("https://i.imgur.com/ejqd6Ro.png")).blob(),
|
|
name: "ddlogo.png",
|
|
},
|
|
});
|
|
const editSticker = await bot.helpers.editGuildSticker(CACHED_COMMUNITY_GUILD_ID, createSticker.id, {
|
|
name: "sticker name",
|
|
description: "sticker description",
|
|
tags: "sticker tags",
|
|
});
|
|
assertEquals(editSticker.name, "sticker name");
|
|
assertEquals(editSticker.description, "sticker description");
|
|
assertEquals(editSticker.tags, "sticker tags");
|
|
|
|
await bot.helpers.deleteGuildSticker(CACHED_COMMUNITY_GUILD_ID, editSticker.id);
|
|
});
|