public void waitForRunCompletion()

in src/main/java/org/jenkinsci/plugins/awsdevicefarm/AWSDeviceFarmTestResultAction.java [78:95]


    public void waitForRunCompletion(AWSDeviceFarm adf, ScheduleRunResult runResult, TaskListener listener) throws InterruptedException {
        PrintStream log = listener.getLogger();
        while (true) {
            GetRunResult latestRunResult = adf.describeRun(runResult.getRun().getArn());
            Run run = latestRunResult.getRun();
            result = new AWSDeviceFarmTestResult(owner, run);
            writeToLog(log, String.format("Run %s status %s", run.getName(), run.getStatus()));
            if (result.isCompleted()) {
                break;
            }
            try {
                Thread.sleep(DefaultUpdateInterval);
            } catch (InterruptedException ex) {
                writeToLog(log, String.format("Thread interrupted while waiting for the Run to complete"));
                throw ex;
            }
        }
    }