cleanup
Some checks failed
Publish Package / build (push) Has been cancelled

This commit is contained in:
Lee
2024-04-15 08:56:26 +01:00
parent 3342f696af
commit b9d79659c8
12 changed files with 150 additions and 219 deletions

View File

@ -1,7 +1,7 @@
import mcUtils from "../src/index";
import { getPlayer, getPlayerSkinPart, getPlayerUuid } from "../dist/index";
test("ensureGetPlayerLookupSuccess", async () => {
const response = await mcUtils.player.getPlayer("Notch");
const response = await getPlayer("Notch");
const { player } = response;
expect(player).toBeDefined();
@ -9,7 +9,7 @@ test("ensureGetPlayerLookupSuccess", async () => {
});
test("ensureGetPlayerUuidSuccess", async () => {
const player = await mcUtils.player.getPlayerUuid("Notch");
const player = await getPlayerUuid("Notch");
expect(player).toBeDefined();
expect(player).toHaveProperty("username");
@ -17,7 +17,7 @@ test("ensureGetPlayerUuidSuccess", async () => {
});
test("ensureGetPlayerSkinPartSuccess", async () => {
const response = await mcUtils.player.getPlayer("Notch");
const response = await getPlayer("Notch");
const { player } = response;
const skin = player.skin;
@ -25,7 +25,7 @@ test("ensureGetPlayerSkinPartSuccess", async () => {
// Test each skin part
for (const part in skinParts) {
const partBuffer = await mcUtils.player.getPlayerSkinPart(part, player.uniqueId);
const partBuffer = await getPlayerSkinPart(part, player.uniqueId);
expect(partBuffer).toBeDefined();
expect(partBuffer.byteLength).toBeGreaterThan(0);
}