FlyteRunnerHandler extends AbstractRunnerHandler { private FlyteExecutionId getFlyteExecutionId(FlyteExecConf flyteExecConf, String execName) { return FlyteExecutionId.create( flyteExecConf.referenceId().project(), flyteExecConf.referenceId().domain(), execName); } FlyteRunnerHandler(FlyteRunner flyteRunner); @VisibleForTesting  FlyteRunnerHandler(FlyteRunner flyteRunner, Function<String, String> styxExecIdToFlyteNameMapper); @Override void safeTransitionInto(final RunState state, final EventRouter eventRouter);  }
@Test public void shouldPollInSubmitted() throws FlyteRunner.PollingException { RunState runState = RunState.create(WORKFLOW_INSTANCE, State.SUBMITTED, StateData.newBuilder() .executionId(EXECUTION_ID) .executionDescription(FLYTE_EXECUTION_DESCRIPTION) .build()); flyteRunnerHandler.transitionInto(runState, eventRouter); verify(flyteRunner).poll(getFlyteExecutionId(FLYTE_EXECUTION_DESCRIPTION, EXECUTION_NAME), runState); }