Skip to content

Commit

Permalink
fix: nullValue matcher does not reify
Browse files Browse the repository at this point in the history
Fixes #1229
  • Loading branch information
mefellows committed Jul 15, 2024
1 parent 74d2e76 commit 811868b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/v3/matchers.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -465,6 +465,7 @@ describe('V3 Matchers', () => {
const result = MatchersV3.nullValue();
expect(result).to.deep.equal({
'pact:matcher:type': 'null',
value: null,
});
});
});
Expand Down Expand Up @@ -604,6 +605,7 @@ describe('V3 Matchers', () => {
more: 'strings',
an: ['array'],
another: MatchersV3.eachLike('this'),
null: MatchersV3.nullValue(),
someObject: {
withData: MatchersV3.like(true),
withTerm: MatchersV3.regex('this|that', 'this'),
Expand All @@ -617,6 +619,7 @@ describe('V3 Matchers', () => {
more: 'strings',
an: ['array'],
another: ['this'],
null: null,
someObject: {
withData: true,
withTerm: 'this',
Expand Down
1 change: 1 addition & 0 deletions src/v3/matchers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,7 @@ export function includes(value: string): Matcher<string> {
export function nullValue(): Matcher<null> {
return {
'pact:matcher:type': 'null',
value: null,
};
}

Expand Down

0 comments on commit 811868b

Please sign in to comment.