import { InternalUnitRuntimeContext , PipelineRuntimeContext , StageRuntimeContext } from '../types' ; import { computeJoint } from './condition-compute' ; export const checkPipelineCondition = ( context ) : boolean => { return computeJoint ( { joint : context . pipeline . on ! , pipelineContext : context , alternativeTriggerData : null } ) ; } ; export const checkStageCondition = ( pipelineContext , context ) : boolean => { return computeJoint ( { joint : context . stage . on ! , pipelineContext , alternativeTriggerData : null } ) ; } ; export const checkInternalUnitCondition = ( pipelineContext , context ) : boolean => { return computeJoint ( { joint : context . unit . on ! , pipelineContext , internalUnitContext : context , alternativeTriggerData : null } ) ; } ;