system: merge info and dmi routes

also return uptimeSecs instead of abstract date
This commit is contained in:
Girish Ramakrishnan
2023-12-04 01:09:42 +01:00
parent eb64bd296a
commit cbf1b47332
5 changed files with 21 additions and 31 deletions

View File

@@ -53,11 +53,13 @@ describe('System', function () {
expect(cpus[0].model).to.be.a('string');
});
it('can get DMI', async function () {
const dmi = await system.getDmi();
it('can get info', async function () {
const info = await system.getInfo();
expect(dmi.sysVendor).to.be.a('string');
expect(dmi.productName).to.be.a('string');
expect(info.sysVendor).to.be.a('string');
expect(info.productName).to.be.a('string');
expect(info.uptimeSecs).to.be.a('number');
expect(info.rebootRequired).to.be.a('boolean');
});
it('can get diskUsage', async function () {