fix(core): update

This commit is contained in:
2022-08-07 11:19:43 +02:00
parent 875c06f86c
commit fcd50a780a
10 changed files with 55 additions and 61 deletions

View File

@@ -12,12 +12,12 @@ tap.test('first test', async () => {
testSmartruleInstance = new smartrule.SmartRule<ITestMessage>();
testSmartruleInstance.createRule(
2,
async messageArg => {
async (messageArg) => {
if (messageArg.body.startsWith('hello')) {
return 'apply-stop';
}
},
async messageArg => {
async (messageArg) => {
console.log(`rule triggered for message with body ${messageArg.body}`);
}
);
@@ -26,7 +26,7 @@ tap.test('first test', async () => {
tap.test('make a decision based on an object', async () => {
testSmartruleInstance.makeDecision({
id: '123456',
body: 'hello, there. This is a cool message!'
body: 'hello, there. This is a cool message!',
});
});