fix(integrations): update PatchMon API key settings link
Point the PatchMon “Get API key” link to /settings/integrations and add coverage for the generated URL. Closes #6284
This commit is contained in:
1 parent
576856d634
commit
fe07d2379a
2 files changed
+7
-1
No files matched your search
@@ -379,7 +379,7 @@ export const integrationDefs = {
|
|||||||
category: ["healthMonitoring"],
|
category: ["healthMonitoring"],
|
||||||
documentationUrl: createDocumentationLink("/docs/integrations/patchmon"),
|
documentationUrl: createDocumentationLink("/docs/integrations/patchmon"),
|
||||||
defaultPort: 3413,
|
defaultPort: 3413,
|
||||||
apiKeySettingsPath: "/settings/api-keys",
|
apiKeySettingsPath: "/settings/integrations",
|
||||||
},
|
},
|
||||||
tracearr: {
|
tracearr: {
|
||||||
name: "Tracearr",
|
name: "Tracearr",
|
||||||
|
|||||||
@@ -15,6 +15,12 @@ describe("getIntegrationApiKeyUrl", () => {
|
|||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("builds URL for patchmon", () => {
|
||||||
|
expect(getIntegrationApiKeyUrl("http://patchmon.local:3413", "patchmon")).toBe(
|
||||||
|
"http://patchmon.local:3413/settings/integrations",
|
||||||
|
);
|
||||||
|
});
|
||||||
|
|
||||||
it("returns null for integrations without apiKeySettingsPath", () => {
|
it("returns null for integrations without apiKeySettingsPath", () => {
|
||||||
expect(getIntegrationApiKeyUrl("http://localhost", "plex")).toBeNull();
|
expect(getIntegrationApiKeyUrl("http://localhost", "plex")).toBeNull();
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in new issue
Block a user