From 13a6c8eac9bc84b122b8e5b91c5f324a4cfb21a7 Mon Sep 17 00:00:00 2001 From: Tim Rozet Date: Wed, 19 Jul 2017 15:24:50 -0400 Subject: [PATCH] Apex: Fixes daily result reporting Breaks testing up into its own mulitjob, which allows us to condtionally set status for the job due to failures, which will be set to unstable if only test suites fail. Change-Id: I5d886b98e437bf100b1d5546aebfcd046b0238cb Signed-off-by: Tim Rozet --- jjb/apex/apex.yml | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++- jjb/apex/apex.yml.j2 | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 120 insertions(+), 2 deletions(-) diff --git a/jjb/apex/apex.yml b/jjb/apex/apex.yml index 6f56dc916..8ef498dbc 100644 --- a/jjb/apex/apex.yml +++ b/jjb/apex/apex.yml @@ -653,8 +653,60 @@ abort-all-job: true git-revision: false - multijob: - name: Functest + name: 'OPNFV Test Suite' condition: SUCCESSFUL + projects: + - name: 'apex-testsuite-{scenario}-baremetal-{scenario_stream}' + node-parameters: true + current-parameters: false + predefined-parameters: + DEPLOY_SCENARIO=$DEPLOY_SCENARIO + kill-phase-on: NEVER + abort-all-job: true + git-revision: false + + +# Baremetal test job +- job-template: + name: 'apex-testsuite-{scenario}-baremetal-{scenario_stream}' + + project-type: 'multijob' + + disabled: false + + parameters: + - '{project}-defaults' + - '{project}-baremetal-{scenario_stream}-defaults' + - project-parameter: + project: '{project}' + branch: '{branch}' + - apex-parameter: + gs-pathname: '{gs-pathname}' + - string: + name: DEPLOY_SCENARIO + default: '{scenario}' + description: "Scenario to deploy with." + properties: + - logrotate-default + - build-blocker: + use-build-blocker: true + block-level: 'NODE' + blocking-jobs: + - 'apex-verify.*' + - 'apex-runner.*' + - 'apex-.*-promote.*' + - 'apex-run.*' + - 'apex-testsuite-.+-baremetal-.+' + - throttle: + max-per-node: 1 + max-total: 10 + option: 'project' + builders: + - description-setter: + description: "Testing on $NODE_NAME - Scenario: $DEPLOY_SCENARIO" + - multijob: + name: Functest + condition: ALWAYS projects: - name: 'functest-apex-baremetal-daily-{scenario_stream}' node-parameters: true @@ -676,6 +728,13 @@ kill-phase-on: NEVER abort-all-job: false git-revision: false + - conditional-step: + condition-kind: current-status + condition-worst: SUCCESS + condtion-best: SUCCESS + on-evaluation-failure: mark-unstable + steps: + - shell: 'echo "Tests Passed"' # danube Daily diff --git a/jjb/apex/apex.yml.j2 b/jjb/apex/apex.yml.j2 index 06c2c3e72..316fe243a 100644 --- a/jjb/apex/apex.yml.j2 +++ b/jjb/apex/apex.yml.j2 @@ -597,8 +597,60 @@ abort-all-job: true git-revision: false - multijob: - name: Functest + name: 'OPNFV Test Suite' condition: SUCCESSFUL + projects: + - name: 'apex-testsuite-{scenario}-baremetal-{scenario_stream}' + node-parameters: true + current-parameters: false + predefined-parameters: + DEPLOY_SCENARIO=$DEPLOY_SCENARIO + kill-phase-on: NEVER + abort-all-job: true + git-revision: false + + +# Baremetal test job +- job-template: + name: 'apex-testsuite-{scenario}-baremetal-{scenario_stream}' + + project-type: 'multijob' + + disabled: false + + parameters: + - '{project}-defaults' + - '{project}-baremetal-{scenario_stream}-defaults' + - project-parameter: + project: '{project}' + branch: '{branch}' + - apex-parameter: + gs-pathname: '{gs-pathname}' + - string: + name: DEPLOY_SCENARIO + default: '{scenario}' + description: "Scenario to deploy with." + properties: + - logrotate-default + - build-blocker: + use-build-blocker: true + block-level: 'NODE' + blocking-jobs: + - 'apex-verify.*' + - 'apex-runner.*' + - 'apex-.*-promote.*' + - 'apex-run.*' + - 'apex-testsuite-.+-baremetal-.+' + - throttle: + max-per-node: 1 + max-total: 10 + option: 'project' + builders: + - description-setter: + description: "Testing on $NODE_NAME - Scenario: $DEPLOY_SCENARIO" + - multijob: + name: Functest + condition: ALWAYS projects: - name: 'functest-apex-baremetal-daily-{scenario_stream}' node-parameters: true @@ -620,6 +672,13 @@ kill-phase-on: NEVER abort-all-job: false git-revision: false + - conditional-step: + condition-kind: current-status + condition-worst: SUCCESS + condtion-best: SUCCESS + on-evaluation-failure: mark-unstable + steps: + - shell: 'echo "Tests Passed"' {% for stream in scenarios %} # {{ stream }} Daily -- 2.16.6