feat: Add testRemoteServerConnection functionality to useRemoteServers hook and update related tests

This commit is contained in:
Wikid82
2025-11-19 20:33:06 -05:00
parent 6f289d3fc7
commit e13223592c
5 changed files with 88 additions and 81 deletions
+5
View File
@@ -38,3 +38,8 @@ export const updateRemoteServer = async (uuid: string, server: Partial<RemoteSer
export const deleteRemoteServer = async (uuid: string): Promise<void> => {
await client.delete(`/remote-servers/${uuid}`);
};
export const testRemoteServerConnection = async (uuid: string): Promise<{ address: string }> => {
const { data } = await client.post<{ address: string }>(`/remote-servers/${uuid}/test`);
return data;
};