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

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

Introduction

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

Prototype

ExecutionResult FAILED

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

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 w ww. j a v a2  s . co  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);
}