smartdaemon/test/test.ts

22 lines
582 B
TypeScript
Raw Normal View History

2019-06-20 12:01:51 +00:00
import { expect, tap } from '@pushrocks/tapbundle';
import * as smartdaemon from '../ts/index';
2019-09-03 13:21:30 +00:00
let testSmartdaemon: smartdaemon.SmartDaemon;
tap.test('should create an instance of smartdaemon', async () => {
testSmartdaemon = new smartdaemon.SmartDaemon();
expect(testSmartdaemon).to.be.instanceOf(smartdaemon.SmartDaemon);
2019-06-20 12:01:51 +00:00
});
2019-09-03 20:09:30 +00:00
tap.test('should create a service', async () => {
testSmartdaemon.addService({
2019-09-05 09:15:17 +00:00
name: 'npmversion',
version: 'x.x.x',
2019-09-03 20:09:30 +00:00
command: 'npm -v',
description: 'displays the npm version',
2021-01-30 00:41:40 +00:00
workingDir: __dirname,
2019-09-03 20:09:30 +00:00
});
});
2019-06-20 12:01:51 +00:00
tap.start();