X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=jjb%2Fyardstick%2Fyardstick-project-jobs.yml;h=e2fee29882ca3cb77b87b2cc7e38ab1dacbeba97;hb=2adb72891c884765d3482b43769448fd99cf086c;hp=1da4f3134f90788fac4f61d1bb34dd4a09ef843b;hpb=d7b0f96d7cf41f2e3b147a067101b848009bb7c2;p=releng.git diff --git a/jjb/yardstick/yardstick-project-jobs.yml b/jjb/yardstick/yardstick-project-jobs.yml index 1da4f3134..e2fee2988 100644 --- a/jjb/yardstick/yardstick-project-jobs.yml +++ b/jjb/yardstick/yardstick-project-jobs.yml @@ -1,3 +1,4 @@ +--- ################################################### # All the jobs except verify have been removed! # They will only be enabled on request by projects! @@ -8,18 +9,18 @@ project: 'yardstick' jobs: - - 'yardstick-verify-{stream}' - - 'yardstick-merge-{stream}' + - 'yardstick-verify-{stream}' + - 'yardstick-merge-{stream}' stream: - - master: - branch: '{stream}' - gs-pathname: '' - disabled: false - - danube: - branch: 'stable/{stream}' - gs-pathname: '/{stream}' - disabled: false + - master: + branch: '{stream}' + gs-pathname: '' + disabled: false + - euphrates: + branch: 'stable/{stream}' + gs-pathname: '/{stream}' + disabled: false ################################ # job templates @@ -31,36 +32,47 @@ disabled: '{obj:disabled}' parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - 'opnfv-build-ubuntu-defaults' + - project-parameter: + project: '{project}' + branch: '{branch}' + - 'opnfv-build-ubuntu-defaults' scm: - - git-scm-gerrit + - git-scm-gerrit triggers: - - gerrit: - server-name: 'gerrit.opnfv.org' - trigger-on: - - patchset-created-event: - exclude-drafts: 'false' - exclude-trivial-rebase: 'false' - exclude-no-code-change: 'false' - - draft-published-event - - comment-added-contains-event: - comment-contains-value: 'recheck' - - comment-added-contains-event: - comment-contains-value: 'reverify' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' + - gerrit: + server-name: 'gerrit.opnfv.org' + trigger-on: + - patchset-created-event: + exclude-drafts: 'false' + exclude-trivial-rebase: 'false' + exclude-no-code-change: 'false' + - draft-published-event + - comment-added-contains-event: + comment-contains-value: 'recheck' + - comment-added-contains-event: + comment-contains-value: 'reverify' + projects: + - project-compare-type: 'ANT' + project-pattern: '{project}' + branches: + - branch-compare-type: 'ANT' + branch-pattern: '**/{branch}' + + wrappers: + - ssh-agent-wrapper + - timeout: + timeout: 30 + fail: true + builders: - - yardstick-unit-tests-and-docs-build + - yardstick-unit-tests-python-27 + - yardstick-unit-tests-python-3 + - yardstick-functional-tests-python-27 + - yardstick-functional-tests-python-3 + - yardstick-coverage-tests + - yardstick-pep8-tests - job-template: name: 'yardstick-merge-{stream}' @@ -68,60 +80,130 @@ disabled: '{obj:disabled}' parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - 'opnfv-build-ubuntu-defaults' - - string: - name: GS_URL - default: '$GS_BASE{gs-pathname}' - description: "Directory where the build artifact will be located upon the completion of the build." + - project-parameter: + project: '{project}' + branch: '{branch}' + - 'opnfv-build-ubuntu-defaults' + - string: + name: GS_URL + default: '$GS_BASE{gs-pathname}' + description: "Directory where the build artifact will be located upon the completion of the build." scm: - - git-scm + - git-scm triggers: - - gerrit: - server-name: 'gerrit.opnfv.org' - trigger-on: - - change-merged-event - - comment-added-contains-event: - comment-contains-value: 'remerge' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' + - gerrit: + server-name: 'gerrit.opnfv.org' + trigger-on: + - change-merged-event + - comment-added-contains-event: + comment-contains-value: 'remerge' + projects: + - project-compare-type: 'ANT' + project-pattern: '{project}' + branches: + - branch-compare-type: 'ANT' + branch-pattern: '**/{branch}' + + wrappers: + - ssh-agent-wrapper + - timeout: + timeout: 30 + fail: true builders: - - yardstick-unit-tests-and-docs-build + - yardstick-unit-tests-python-27 + - yardstick-unit-tests-python-3 + - yardstick-functional-tests-python-27 + - yardstick-functional-tests-python-3 + - yardstick-coverage-tests + - yardstick-pep8-tests ################################ # job builders ################################ - builder: - name: yardstick-unit-tests-and-docs-build + name: yardstick-unit-tests-python-27 + builders: + - shell: | + #!/bin/bash + set -o errexit + set -o pipefail + + sudo apt-get install -y build-essential python-dev python3-dev + + echo "Running unit tests in Python 2.7 ..." + cd $WORKSPACE + tox -epy27 + +- builder: + name: yardstick-unit-tests-python-3 + builders: + - shell: | + #!/bin/bash + set -o errexit + set -o pipefail + + sudo apt-get install -y build-essential python-dev python3-dev + + echo "Running unit tests in Python 3 ..." + cd $WORKSPACE + tox -epy3 + +- builder: + name: yardstick-functional-tests-python-27 + builders: + - shell: | + #!/bin/bash + set -o errexit + set -o pipefail + + sudo apt-get install -y build-essential python-dev python3-dev + + echo "Running functional tests in Python 2.7 ..." + cd $WORKSPACE + tox -efunctional + +- builder: + name: yardstick-functional-tests-python-3 + builders: + - shell: | + #!/bin/bash + set -o errexit + set -o pipefail + + sudo apt-get install -y build-essential python-dev python3-dev + + echo "Running functional tests in Python 3 ..." + cd $WORKSPACE + tox -efunctional-py3 + +- builder: + name: yardstick-coverage-tests builders: - - shell: | - #!/bin/bash - set -o errexit - set -o pipefail - - echo "Running unit tests..." - cd $WORKSPACE - virtualenv $WORKSPACE/yardstick_venv - source $WORKSPACE/yardstick_venv/bin/activate - - # install python packages - easy_install -U setuptools==33.1.1 - easy_install -U pip - pip install -r requirements.txt || pip install -r tests/ci/requirements.txt - pip install -e . - - # unit tests - ./run_tests.sh - - deactivate + - shell: | + #!/bin/bash + set -o errexit + set -o pipefail + + sudo apt-get install -y build-essential python-dev python3-dev + + echo "Running coverage tests ..." + cd $WORKSPACE + tox -ecoverage + +- builder: + name: yardstick-pep8-tests + builders: + - shell: | + #!/bin/bash + set -o errexit + set -o pipefail + + sudo apt-get install -y build-essential python-dev python3-dev + + echo "Running style guidelines (PEP8) tests ..." + cd $WORKSPACE + tox -epep8