Son CV dans un terminal web en Javascript! https://terminal-cv.gregandev.fr
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

19 lines
506 B

import assert from 'assert';
import os from 'os';
import getCores, {detectRealCores} from '../src/cpuCount';
describe('cpuCount', function() {
it('Should be able to detect real cpu count', () => {
// Windows not supported as getting the cpu count takes a couple seconds...
if (os.platform() === 'win32') return;
let cores = detectRealCores();
assert(cores > 0);
});
it('getCores should return more than 0', () => {
let cores = getCores(true);
assert(cores > 0);
});
});