@case-contract-testing/case
Version:
Next-generation contract testing suite
13 lines (12 loc) • 508 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.CaseCoreError = void 0;
const locationString = (matchContext) => `(at ${matchContext['case:currentRun:context:location'].join('.')})`;
class CaseCoreError extends Error {
constructor(message, context) {
super(`${message}${context ? locationString(context) : ''}`);
Object.setPrototypeOf(this, new.target.prototype);
this.name = CaseCoreError.name;
}
}
exports.CaseCoreError = CaseCoreError;