Skip to content

Commit a240206

Browse files
Shawclaude
andcommitted
fix(plugin-roblox): replace uuid dependency with node:crypto in test
The executeGameAction test imported from the 'uuid' package which wasn't listed in the plugin's dependencies, causing ERR_MODULE_NOT_FOUND in CI. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 2c8a33d commit a240206

1 file changed

Lines changed: 9 additions & 9 deletions

File tree

plugins/plugin-roblox/__tests__/executeGameAction.test.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { ChannelType, createMessageMemory, type UUID } from "@elizaos/core";
2-
import { v4 as uuidv4 } from "uuid";
2+
import { randomUUID } from "node:crypto";
33
import { describe, expect, it } from "vitest";
44
import executeGameAction from "../actions/executeGameAction";
55

@@ -25,14 +25,14 @@ describe("EXECUTE_ROBLOX_ACTION parsing", () => {
2525
it("parses move_npc waypoint from user message", async () => {
2626
const service = new FakeRobloxService();
2727
const runtime = {
28-
agentId: uuidv4() as UUID,
28+
agentId: randomUUID() as UUID,
2929
getService: <T>(_name: string) => service as never as T,
3030
};
3131

3232
const msg = createMessageMemory({
33-
id: uuidv4() as UUID,
34-
entityId: uuidv4() as UUID,
35-
roomId: uuidv4() as UUID,
33+
id: randomUUID() as UUID,
34+
entityId: randomUUID() as UUID,
35+
roomId: randomUUID() as UUID,
3636
content: {
3737
text: "move the npc to spawn",
3838
source: "test",
@@ -50,14 +50,14 @@ describe("EXECUTE_ROBLOX_ACTION parsing", () => {
5050
it("parses move_npc coordinates from user message", async () => {
5151
const service = new FakeRobloxService();
5252
const runtime = {
53-
agentId: uuidv4() as UUID,
53+
agentId: randomUUID() as UUID,
5454
getService: <T>(_name: string) => service as never as T,
5555
};
5656

5757
const msg = createMessageMemory({
58-
id: uuidv4() as UUID,
59-
entityId: uuidv4() as UUID,
60-
roomId: uuidv4() as UUID,
58+
id: randomUUID() as UUID,
59+
entityId: randomUUID() as UUID,
60+
roomId: randomUUID() as UUID,
6161
content: {
6262
text: "move to (1, 2, 3)",
6363
source: "test",

0 commit comments

Comments
 (0)