UNPKG

offensive

Version:

Fast and boilerplate-free precondition checks for javascript.

23 lines (22 loc) 745 B
import { Assertion, StandardMessage, ContractFunction } from '../../model'; import '../aDate'; import '../../connectors'; /** * @author Maciej Chałapuk (maciej@chalapuk.pl) */ export declare class BeforeAssertion<T> implements Assertion<T> { private comparedDate; private comparedVarName?; constructor(comparedDate: Date, comparedVarName?: string | undefined); assert(varName: string, testedValue: T, contract: ContractFunction): { readonly success: boolean; readonly message: StandardMessage; }; } export declare namespace BeforeAssertion { /** * @author Maciej Chałapuk (maciej@chalapuk.pl) */ function factory(args: any[]): BeforeAssertion<unknown>; } export default BeforeAssertion;