Skip to content

Commit 22dcd7d

Browse files
author
Cache Hamm
committed
Add typescript test for pathresolver
1 parent f6e27a0 commit 22dcd7d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

types/index.test-d.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import rulesEngine, {
77
Fact,
88
Operator,
99
OperatorEvaluator,
10+
PathResolver,
1011
Rule,
1112
RuleProperties,
1213
RuleSerializable
@@ -44,6 +45,10 @@ const complexRuleProps: RuleProperties = {
4445
}
4546
};
4647

48+
// path resolver
49+
const pathResolver = function(value: object, path: string): any {}
50+
expectType<PathResolver>(pathResolver)
51+
4752
// default export test
4853
expectType<Engine>(rulesEngine([ruleProps]));
4954
const engine = rulesEngine([complexRuleProps]);

0 commit comments

Comments
 (0)