2017-04-28 07:49:57 +00:00
|
|
|
import { TapTools } from './tapbundle.classes.taptools';
|
|
|
|
import { HrtMeasurement } from 'early';
|
2017-05-04 21:15:08 +00:00
|
|
|
import { Deferred } from 'smartq';
|
2017-04-28 07:49:57 +00:00
|
|
|
export declare type TTestStatus = 'success' | 'error' | 'pending' | 'errorAfterSuccess' | 'timeout';
|
|
|
|
export interface ITestFunction {
|
|
|
|
(tapTools?: TapTools): Promise<any>;
|
|
|
|
}
|
|
|
|
export declare class TapTest {
|
|
|
|
description: string;
|
|
|
|
failureAllowed: boolean;
|
|
|
|
hrtMeasurement: HrtMeasurement;
|
|
|
|
parallel: boolean;
|
|
|
|
status: TTestStatus;
|
|
|
|
tapTools: TapTools;
|
|
|
|
testFunction: ITestFunction;
|
2017-05-04 21:15:08 +00:00
|
|
|
testDeferred: Deferred<TapTest>;
|
|
|
|
testPromise: Promise<TapTest>;
|
2017-04-28 07:49:57 +00:00
|
|
|
/**
|
|
|
|
* constructor
|
|
|
|
*/
|
|
|
|
constructor(optionsArg: {
|
|
|
|
description: string;
|
|
|
|
testFunction: ITestFunction;
|
|
|
|
parallel: boolean;
|
|
|
|
});
|
|
|
|
/**
|
|
|
|
* run the test
|
|
|
|
*/
|
|
|
|
run(testKeyArg: number): Promise<void>;
|
|
|
|
}
|