test: fix various routes tests

* system/disks routes is gone
* provision routes now return 405 instead of 409 when re-setup/re-activated
This commit is contained in:
Girish Ramakrishnan
2024-06-03 19:18:36 +02:00
parent db7e88e302
commit 3dcd0975f7
4 changed files with 9 additions and 21 deletions

View File

@@ -32,8 +32,8 @@ const TASKS = { // indexed by task type
syncDyndns: dyndns.sync,
updateDiskUsage: system.updateDiskUsage,
_identity: async (arg, progressCallback) => { progressCallback(); return arg; },
_error: async (arg, progressCallback) => { progressCallback(); throw new Error(`Failed for arg: ${arg}`); },
_identity: async (arg, progressCallback) => { progressCallback({}); return arg; },
_error: async (arg, progressCallback) => { progressCallback({}); throw new Error(`Failed for arg: ${arg}`); },
_crash: (arg) => { throw new Error(`Crashing for arg: ${arg}`); }, // the test looks for this debug string in the log file
_sleep: async (arg) => setTimeout(process.exit, arg)
};