export class AssertionError extends Error {
    /**
     * Set with assertions to show the actual value at the time of testing.
     */
    actual;
    /**
     * Set with assertions to show the expected value at the time of testing.
     */
    expected;
    /**
     * The operator used to make the assertion.
     */
    operator;
    code = 'ERR_ASSERTION';
    constructor(options = {}) {
        super(options.message || 'Unspecified AssertionError');
        this.name = 'AssertionError';
        this.actual = options.actual;
        this.expected = options.expected;
        this.operator = options.operator || '[unknown]';
    }
    toJSON() {
        const result = {};
        if (this.message) {
            result.message = this.message;
        }
        result.actual = this.actual;
        result.expected = this.expected;
        if (this.operator) {
            result.operator = this.operator;
        }
        return result;
    }
}
//# sourceMappingURL=AssertionError.js.map