import { StepName } from './StepName' ; declare global { namespace Prescript { interface GlobalState { [ key ] : unknown ; } interface PrescriptionState { [ key ] : unknown ; } } } public export type StepDefName = StepName | string ; /**
 * Configuration defined in the `prescript.config.js` file.
 * For more information, see the  https .
 *  public export interface IConfig { remarks alpha wrapAction ? : ActionWrapper ; remarks param testModulePath alpha createTestReporter ? ( testModulePath , testName ) : ITestReporter ; } alpha export type ActionWrapper = ( step : IStep , execute : ( ) => Promise < void > , state : Prescript . GlobalState , context : ITestExecutionContext ) => Promise < void > ; alpha export interface IStep { name : StepName ; number ? : string ; children ? : IStep [ ] ; creator ? : string ; definition ? : string ; independent ? : boolean ; action ? : ActionFunction ; actionDefinition ? : string ; pending ? : boolean ; cleanup ? : boolean ; defer ? : boolean ; } export interface ITestLoadLogger { step ( step ) : void ; test ( name ) : void ; } export interface IPrescriptAPI { test < X > ( name , f ) : X ; test ( nameParts , ... substitutions ) : < X > ( f : ( ) => X ) => X ; to < X > ( name , f ) : X ; to ( nameParts , ... substitutions ) : < X > ( f : ( ) => X ) => X ; action ( name , f ) : void ; action ( nameParts , ... substitutions ) : ( f : ActionFunction ) => void ; action ( f ) : void ; defer ( name , f ) : void ; defer ( nameParts , ... substitutions ) : ( f : ActionFunction ) => void ; pending ( ) : void ; step < X > ( name , f ) : X ; cleanup < X > ( name , f ) : X ; onFinish ( f ) : void ; independent < X > ( f ) : X ; use ( f ) : void ; } public export interface ITestExecutionContext { param format param args log ( format , ... args ) : void ; param name param buffer param mimeType attach ( name , buffer , mimeType ) : void ; } export interface IIterationListener { onEnter : ( node : IStep ) => void ; onExit : ( node : IStep , error ? : Error ) => void ; } alpha export interface ITestReporter { param errors - Errors that occurred during the test.
     *  If there are no errors, this will be an empty array.
     *  Note that pending tests are treated the same way as errors.
     *  To check if an error object represents a pending test, use the  isPendingError function.
      onFinish ( errors ) : void ; param step onEnterStep ( step ) : void ; param step param error onExitStep ( step , error ? ) : void ; } export interface IVisitor { visitNode ( node ) ; visitDeferNode ( node ) ; } export interface ITestIterator { setTest ( test ) ; getTest ( ) : IStep ; begin ( beginningStep ? ) ; getCurrentStepNumber ( ) : string | null ; getCurrentStep ( ) : IStep ; isDone ( ) : boolean ; actionPassed ( ) : void ; actionFailed ( error ) : void ; } public export interface Thenable { then ( onFulfilled ? , onRejected ? ) : Thenable ; } public export type ActionFunction = ( state : Prescript . GlobalState , context : ITestExecutionContext ) => void | Thenable ;