system-config/modules/openstack_project/files/jenkins_job_builder/config/chef-jobs.yaml
Matt Ray 7ae6c01f09 Chef style testing enablement and minor speed cleanup starting with checks
Broke the chef-cookbook-prep builder into bundler and berkshelf steps because
both are not needed for every test. Renamed builders to reflect the underlying
tools used:

  chef-cookbook-prep  -> chef-bundler-prep
                      -> chef-berkshelf-prep
  chef-cookbook-rspec -> chef-cookbook-chefspec
  chef-cookbook-lint  -> chef-cookbook-foodcritic
  chef-cookbook-style -> chef-cookbook-rubocop

Enabled rubocop/style checks without gating for all cookbooks. Will add gating
once the Rubocop updates are in place and this is shown to work well.

Addresses: blueprint lint-and-unit-testing-for-havana
Change-Id: I894f5aefe650ef799ac1aa10345749d2a86f0074
2014-01-22 13:04:44 -06:00

55 lines
1.1 KiB
YAML

- job-template:
name: 'gate-{name}-chef-unit'
node: '{node}'
builders:
- gerrit-git-prep
- chef-bundler-prep
- chef-berkshelf-prep
- chef-cookbook-chefspec
publishers:
- console-log
- job-template:
name: 'gate-{name}-chef-lint'
node: '{node}'
builders:
- gerrit-git-prep
- chef-bundler-prep
- chef-cookbook-foodcritic
publishers:
- console-log
- job-template:
name: 'gate-{name}-chef-style'
node: '{node}'
builders:
- gerrit-git-prep
- chef-bundler-prep
- chef-cookbook-rubocop
publishers:
- console-log
- job:
name: gate-openstack-chef-repo
node: precise
builders:
- gerrit-git-prep
- shell: |
#!/bin/bash -xe
mkdir -p .cookbooks .bundle
ruby1.9.1 /usr/bin/bundle install --path=.bundle
# Validates cookbooks
ruby1.9.1 /usr/bin/bundle exec berks install --path=.cookbooks
# Validates roles
ruby1.9.1 /usr/bin/bundle exec spiceweasel infrastructure.yml --debug
publishers:
- console-log