BREAKING CHANGE(docs): Update documentation and examples to unify async and sync assertions, add custom matcher guides, and update package configuration

This commit is contained in:
2025-04-28 19:10:27 +00:00
parent 6f1e37cf56
commit 47458118a6
19 changed files with 606 additions and 663 deletions

24
ts/namespaces/boolean.ts Normal file
View File

@ -0,0 +1,24 @@
import { Assertion } from '../smartexpect.classes.assertion.js';
/**
* Namespace for boolean-specific matchers
*/
export class BooleanMatchers {
constructor(private assertion: Assertion<boolean>) {}
toBeTrue() {
return this.assertion.toBeTrue();
}
toBeFalse() {
return this.assertion.toBeFalse();
}
toBeTruthy() {
return this.assertion.toBeTruthy();
}
toBeFalsy() {
return this.assertion.toBeFalsy();
}
}