mirror of
https://github.com/louislam/uptime-kuma.git
synced 2025-08-09 10:07:42 +08:00
Uptime calculation improvement and 1-year uptime (#2750)
This commit is contained in:
@@ -847,29 +847,6 @@ exports.doubleCheckPassword = async (socket, currentPassword) => {
|
||||
return user;
|
||||
};
|
||||
|
||||
/**
|
||||
* Start Unit tests
|
||||
* @returns {void}
|
||||
*/
|
||||
exports.startUnitTest = async () => {
|
||||
console.log("Starting unit test...");
|
||||
const npm = /^win/.test(process.platform) ? "npm.cmd" : "npm";
|
||||
const child = childProcess.spawn(npm, [ "run", "jest-backend" ]);
|
||||
|
||||
child.stdout.on("data", (data) => {
|
||||
console.log(data.toString());
|
||||
});
|
||||
|
||||
child.stderr.on("data", (data) => {
|
||||
console.log(data.toString());
|
||||
});
|
||||
|
||||
child.on("close", function (code) {
|
||||
console.log("Jest exit code: " + code);
|
||||
process.exit(code);
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* Start end-to-end tests
|
||||
* @returns {void}
|
||||
|
Reference in New Issue
Block a user