Example usage for com.amazonaws.services.devicefarm.model ExecutionResult ERRORED

List of usage examples for com.amazonaws.services.devicefarm.model ExecutionResult ERRORED

Introduction

In this page you can find the example usage for com.amazonaws.services.devicefarm.model ExecutionResult ERRORED.

Prototype

ExecutionResult ERRORED

To view the source code for com.amazonaws.services.devicefarm.model ExecutionResult ERRORED.

Click Source Link

Usage

From source file:org.jenkinsci.plugins.awsdevicefarm.AWSDeviceFarmTestResult.java

License:Open Source License

/**
 * Return a Jenkins build result which matches the result status from AWS Device Farm.
 *
 * @return//from  www .  j  a v a 2s .c  o  m
 */
public Result getBuildResult(Boolean ignoreRunError) {
    if (ignoreRunError != null && ignoreRunError && ExecutionResult.ERRORED.equals(result)) {
        if (totalCount == skipCount) {
            result = ExecutionResult.SKIPPED;
        } else if (stopCount > 0) {
            result = ExecutionResult.STOPPED;
        } else if (errorCount > 0) {
            result = ExecutionResult.ERRORED;
        } else if (failCount > 0) {
            result = ExecutionResult.FAILED;
        } else if (warnCount > 0) {
            result = ExecutionResult.WARNED;
        } else {
            result = ExecutionResult.PASSED;
        }
    }
    return resultMap.get(result);
}