reference tests as examples

Remove samples and reference the tests as examples instead.

We don't need these samples for two reasons:
1. It is already duplicated in either JJB tests or documentation.
2. We don't test these samples so they may become outdated (some already have).

Change-Id: If1ba6cc8a675091e740fa254951bb8fcbcee6903
This commit is contained in:
Khai Do 2014-05-28 14:01:38 -07:00 committed by zaro0508
parent 24ce90ea84
commit f594fb5c7c
5 changed files with 6 additions and 147 deletions

View File

@ -1,8 +1,9 @@
# Jenkins Job Builder Examples # # Jenkins Job Builder Examples #
These examples demonstrate the use of particular features of Jenkins Jenkins Job Builder includes many tests to demonstrate the use of Jenkins
Job Builder that can be used as starting points for new projects. Job Builder. All of the tests are in the 'tests' folder. It can be used
as a starting point for new projects. The tests also serve as JJB docs.
These examples are also used in the test framework - if you add a new Please look in the tests folder for examples of how to define yaml files
example here, please ensure that it can be processed by Jenkins Job for use with JJB. Most of the test examples are snippets of yaml, for a
Builder. more complete example look at the tests in the 'tests/yamlparser' folder.

View File

@ -1,28 +0,0 @@
- job:
name: test-gerrit-trigger
triggers:
- gerrit:
trigger-on-change-abandoned-event: true
trigger-on-change-merged-event: true
trigger-on-change-restored-event: true
trigger-on-comment-added-event: true
trigger-on-draft-published-event: true
trigger-on-patchset-uploaded-event: true
trigger-on-ref-updated-event: false
trigger-approval-category: CRVW
trigger-approval-value: 2
failure-message:
skip-vote:
successful: true
failed: false
# Missing outcome should default to false.
# unstable: false
notbuilt: true
projects:
- project-compare-type: 'PLAIN'
project-pattern: 'myproject'
branch-compare-type: 'PLAIN'
branch-pattern: 'master'
file-paths:
- compare-type: ANT
pattern: subdirectory/**

View File

@ -1,73 +0,0 @@
# Sample YAML representation of a flexible pipeline for use with the
# Jenkins Build Pipeline Plugin
# (https://wiki.jenkins-ci.org/display/JENKINS/Build+Pipeline+Plugin)
# The pipeline is defined at the project level, using job-specific variable
# substitution to specify the next job in the pipeline ('pipeline-next')
# for each job.
#
# This example defines the skeleton of two deployment pipelines: one for
# a 'base_os' subsystem to three chef servers, and the second to
# a 'database' subsystem to two chef servers.
#
# The pipeline uses an automatically-executed job in '{subsys}-prepare'
# (using the Parameterized Trigger Plugin -
# https://wiki.jenkins-ci.org/display/JENKINS/Parameterized+Trigger+Plugin),
# and manually-triggered jobs using the Pipeline publisher (e.g.
# '{subsys}-initialise').
#
# Note how each project defines a different pipeline, with a different
# length, but re-uses the same job templates.
- project:
name: deploy_base_os
subsys: base_os
jobs:
- '{subsys}-prepare':
pipeline-next: '{subsys}-initialise'
- '{subsys}-initialise':
pipeline-next: '{subsys}-upload-chef-server1'
- '{subsys}-upload-chef-server1':
pipeline-next: '{subsys}-upload-chef-server2'
- '{subsys}-upload-chef-server2':
pipeline-next: '{subsys}-upload-chef-server3'
- '{subsys}-upload-chef-server3':
pipeline-next: ''
- project:
name: deploy_database
subsys: db
jobs:
- '{subsys}-prepare':
pipeline-next: '{subsys}-initialise'
- '{subsys}-initialise':
pipeline-next: '{subsys}-upload-chef-server1'
- '{subsys}-upload-chef-server1':
pipeline-next: '{subsys}-upload-chef-server2'
- '{subsys}-upload-chef-server2':
pipeline-next: ''
- job-template:
name: '{subsys}-prepare'
builders:
- trigger-builds:
- project: '{pipeline-next}'
- job-template:
name: '{subsys}-initialise'
publishers:
- pipeline: '{pipeline-next}'
- job-template:
name: '{subsys}-upload-chef-server1'
publishers:
- pipeline: '{pipeline-next}'
- job-template:
name: '{subsys}-upload-chef-server2'
publishers:
- pipeline: '{pipeline-next}'
- job-template:
name: '{subsys}-upload-chef-server3'
publishers:
- pipeline: '{pipeline-next}'

View File

@ -1,28 +0,0 @@
- job:
name: 'test-release'
wrappers:
- release:
keep-forever: false
override-build-parameters: true
version-template: '${RELEASE_VERSION}'
parameters:
- string:
name: RELEASE_BRANCH
default: ''
description: 'The release branch to build'
pre-build:
- shell: |
#!/bin/bash
echo "echo pre-build builder"
post-build:
- shell: |
#!/bin/bash
echo "echo post-build builder"
post-success:
- shell: |
#!/bin/bash
echo "echo post-success builder"
post-fail:
- shell: |
#!/bin/bash
echo "echo post-fail builder"

View File

@ -1,13 +0,0 @@
- job:
name: test-sonar
publishers:
- sonar:
jdk: MyJdk
branch: myBranch
language: java
maven-opts: -DskipTests
additional-properties: -DsonarHostURL=http://example.com/
skip-global-triggers:
skip-when-scm-change: true
skip-when-upstream-build: true
skip-when-envvar-defined: SKIP_SONAR