mirror of
https://github.com/tale/headplane.git
synced 2026-08-19 09:26:18 +00:00
feat: make api calls more resilient and stuff
This commit is contained in:
@@ -81,8 +81,8 @@ describe("DockerIntegration", () => {
|
||||
socketPath: "/var/run/docker.sock",
|
||||
});
|
||||
|
||||
const mockClient = {
|
||||
isHealthy: async () => {
|
||||
const mockHeadscale = {
|
||||
health: async () => {
|
||||
try {
|
||||
const res = await dockerClient.request({
|
||||
method: "GET",
|
||||
@@ -96,9 +96,9 @@ describe("DockerIntegration", () => {
|
||||
},
|
||||
} as any;
|
||||
|
||||
await integration.onConfigChange(mockClient);
|
||||
await integration.onConfigChange(mockHeadscale);
|
||||
|
||||
const healthy = await mockClient.isHealthy();
|
||||
const healthy = await mockHeadscale.health();
|
||||
expect(healthy).toBe(true);
|
||||
}, 60_000);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user