private void runTest() { if (ddTestRunner == null) return; displayView.startTest(); createRuntime( ddTestRunner.getScriptText(), ddTestRunner.getConsole(), MarathonMode.PLAYING.getMode()); script = runtime.createScript(ddTestRunner.getScriptText(), displayView.getFilePath(), false, true); script.setDataVariables(ddTestRunner.getDataVariables()); player = script.getPlayer(this, playbackResultProvider.get()); player.setAcceptCheckList(acceptingChecklists); boolean shouldRunFixture = state.isStoppedWithAppClosed(); setState(State.PLAYING); displayView.startInserting(); player.play(shouldRunFixture); }
public String evaluateScript(String code) { if (state.isRecordingPaused()) { return runtime.evaluate(code); } else { return script.getDebugger().evaluateScriptWhenPaused(code); } }
public void resume() { if (state.isRecordingPaused()) { runtime.startRecording(recorder); setState(State.RECORDING); } else { script.getDebugger().resume(); setState(State.PLAYING); } }