Skip to content

Commit 23b3dac

Browse files
test(grok): update mocks and assertions for new first-class grok vendor
Co-Authored-By: First Fluke <our.first.fluke@gmail.com>
1 parent ec2cfd3 commit 23b3dac

8 files changed

Lines changed: 23 additions & 0 deletions

File tree

cli/__tests__/hook-variants.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ const KNOWN_VENDORS: VendorType[] = [
1313
"codex",
1414
"cursor",
1515
"gemini",
16+
"grok",
1617
"qwen",
1718
];
1819

cli/commands/auth-status/auth-status.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ describe("auth:status command", () => {
7878
cursor: true,
7979
qwen: true,
8080
antigravity: false,
81+
grok: false,
8182
});
8283
});
8384
});
@@ -103,6 +104,7 @@ describe("auth:status command", () => {
103104
cursor: false,
104105
qwen: false,
105106
antigravity: false,
107+
grok: false,
106108
});
107109
});
108110
});

cli/commands/doctor/doctor.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,11 @@ vi.mock("../../platform/skills-installer.js", () => ({
7474
}));
7575

7676
vi.mock("../../vendors/index.js", () => ({
77+
isAntigravityAuthenticated: vi.fn(() => false),
7778
isClaudeAuthenticated: vi.fn(() => false),
7879
isCodexAuthenticated: vi.fn(() => false),
7980
isGeminiAuthenticated: vi.fn(() => false),
81+
isGrokAuthenticated: vi.fn(() => false),
8082
isQwenAuthenticated: vi.fn(() => false),
8183
}));
8284

cli/commands/doctor/install-skills.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,11 @@ vi.mock("../../io/tarball.js", () => tarballState);
3636
vi.mock("../../platform/skills-installer.js", () => skillsState);
3737

3838
vi.mock("../../vendors/index.js", () => ({
39+
isAntigravityAuthenticated: vi.fn(() => false),
3940
isClaudeAuthenticated: vi.fn(() => false),
4041
isCodexAuthenticated: vi.fn(() => false),
4142
isGeminiAuthenticated: vi.fn(() => false),
43+
isGrokAuthenticated: vi.fn(() => false),
4244
isQwenAuthenticated: vi.fn(() => false),
4345
}));
4446

cli/commands/doctor/profile-subdir.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,11 @@ import { join } from "node:path";
1313
import { afterEach, beforeEach, describe, expect, it, vi } from "vitest";
1414

1515
vi.mock("../../vendors/index.js", () => ({
16+
isAntigravityAuthenticated: vi.fn(() => false),
1617
isClaudeAuthenticated: vi.fn(() => false),
1718
isCodexAuthenticated: vi.fn(() => false),
1819
isGeminiAuthenticated: vi.fn(() => false),
20+
isGrokAuthenticated: vi.fn(() => false),
1921
isQwenAuthenticated: vi.fn(() => false),
2022
}));
2123

cli/commands/doctor/profile.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ vi.mock("../../vendors/index.js", () => ({
2222
isClaudeAuthenticated: vi.fn(() => false),
2323
isCodexAuthenticated: vi.fn(() => false),
2424
isGeminiAuthenticated: vi.fn(() => false),
25+
isGrokAuthenticated: vi.fn(() => false),
2526
isQwenAuthenticated: vi.fn(() => false),
2627
}));
2728

cli/commands/update/update-global.test.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,17 @@ const migrationsState = vi.hoisted(() => ({
9393
const skillsState = vi.hoisted(() => ({
9494
REPO: "first-fluke/oh-my-agent",
9595
INSTALLED_SKILLS_DIR: ".agents/skills",
96+
ALL_CLI_VENDORS: [
97+
"antigravity",
98+
"claude",
99+
"codex",
100+
"copilot",
101+
"cursor",
102+
"gemini",
103+
"grok",
104+
"hermes",
105+
"qwen",
106+
],
96107
}));
97108

98109
// ---------------------------------------------------------------------------

cli/platform/vendor-config.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ describe("readVendorsFromConfig", () => {
4444
"copilot",
4545
"cursor",
4646
"gemini",
47+
"grok",
4748
"hermes",
4849
"qwen",
4950
]);
@@ -59,6 +60,7 @@ describe("readVendorsFromConfig", () => {
5960
"copilot",
6061
"cursor",
6162
"gemini",
63+
"grok",
6264
"hermes",
6365
"qwen",
6466
]);

0 commit comments

Comments
 (0)