mirror of
https://github.com/louislam/uptime-kuma.git
synced 2025-08-09 23:16:32 +08:00
chore(jsdoc):Linting fixes (#3703)
* fixed the lockfile having a different version * jsdoc
This commit is contained in:
@@ -353,18 +353,18 @@ test("Test get1YearUptime (1 check per day)", async (t) => {
|
||||
|
||||
/**
|
||||
* Code from here: https://stackoverflow.com/a/64550489/1097815
|
||||
* @returns {{rss: string, heapTotal: string, heapUsed: string, external: string}} Current memory usage
|
||||
*/
|
||||
function memoryUsage() {
|
||||
const formatMemoryUsage = (data) => `${Math.round(data / 1024 / 1024 * 100) / 100} MB`;
|
||||
const memoryData = process.memoryUsage();
|
||||
|
||||
const memoryUsage = {
|
||||
return {
|
||||
rss: `${formatMemoryUsage(memoryData.rss)} -> Resident Set Size - total memory allocated for the process execution`,
|
||||
heapTotal: `${formatMemoryUsage(memoryData.heapTotal)} -> total size of the allocated heap`,
|
||||
heapUsed: `${formatMemoryUsage(memoryData.heapUsed)} -> actual memory used during the execution`,
|
||||
external: `${formatMemoryUsage(memoryData.external)} -> V8 external memory`,
|
||||
};
|
||||
return memoryUsage;
|
||||
}
|
||||
|
||||
test("Worst case", async (t) => {
|
||||
|
Reference in New Issue
Block a user