fix(core): update
This commit is contained in:
14
test/test.ts
14
test/test.ts
@ -1,12 +1,12 @@
|
||||
import { expect, tap } from '@pushrocks/tapbundle';
|
||||
import { expect, tap } from '@push.rocks/tapbundle';
|
||||
|
||||
import * as smartinteract from '../ts/index';
|
||||
import * as smartinteract from '../ts/index.js';
|
||||
|
||||
let testInteract: smartinteract.SmartInteract;
|
||||
|
||||
tap.test('should create a valid new instance', async () => {
|
||||
testInteract = new smartinteract.SmartInteract();
|
||||
expect(testInteract).to.be.instanceOf(smartinteract.SmartInteract);
|
||||
expect(testInteract).toBeInstanceOf(smartinteract.SmartInteract);
|
||||
});
|
||||
|
||||
tap.test('should get a simple confirmation', async () => {
|
||||
@ -14,7 +14,7 @@ tap.test('should get a simple confirmation', async () => {
|
||||
'You feel awesome, right?',
|
||||
true
|
||||
);
|
||||
expect(response).to.be.true;
|
||||
expect(response).toBeTrue();
|
||||
});
|
||||
|
||||
tap.test('should add question to SmartInteract instance', async () => {
|
||||
@ -46,9 +46,9 @@ tap.test('should add question to SmartInteract instance', async () => {
|
||||
|
||||
tap.test('should use default value when not in CI', async () => {
|
||||
const answerBucket = await testInteract.runQueue();
|
||||
expect(answerBucket.getAnswerFor('testQuestion1')).to.equal('blue');
|
||||
expect(answerBucket.getAnswerFor('testQuestion2')).to.equal('red');
|
||||
expect(answerBucket.getAnswerFor('some.dotted.name')).to.equal('aValidAnswer');
|
||||
expect(answerBucket.getAnswerFor('testQuestion1')).toEqual('blue');
|
||||
expect(answerBucket.getAnswerFor('testQuestion2')).toEqual('red');
|
||||
expect(answerBucket.getAnswerFor('some.dotted.name')).toEqual('aValidAnswer');
|
||||
});
|
||||
|
||||
tap.start();
|
||||
|
Reference in New Issue
Block a user