15 Commits

Author SHA1 Message Date
ZhongShengping
4a342c4289 Load puppet-openstack_spec_helper locally during tests
Change-Id: I89a971f4d71434c2d077be4f89244cd797e22d64
Co-Authored-By: Mohammed Naser <mnaser@vexxhost.com>
2018-02-12 10:53:40 +08:00
Alex Schultz
48954b3fda Update tox configuration
Update the tox configuration to pull in the openstack
upper-constraints.txt when running releasenotes. This will
fix the releasenotes job that is currently failing due to
a new version of sphinx. Additionally this change includes
updates from puppet-modulesync-configs.

Change-Id: Ie587bfde2367dfec796f1b07c01bba15d839a3b1
Related-Bug: #1691511
2017-05-17 17:04:02 +00:00
Emilien Macchi
1c4fe921e6 Switch puppet-tripleo to use puppet-openstack_spec_helper
Align puppet-tripleo with other Puppet OpenStack modules to use
puppet-openstack_spec_helper.

Here are the benefits:

- Allow to use Depends-On between Puppet OpenStack modules and
  puppet-tripleo, and unit tests will work correctly with dependencies.
- Use the Puppet OpenStack gemspec file that handle gems dependencies to
  test the module.
- Allow to re-use ruby helper that Puppet OpenStack modules have in unit
  tests, to avoid duplicated code.
- Don't manage .fixtures.yml file, it will be generated by Puppet
  OpenStack tooling. TripleO dependencies will live in Puppetfile_extras.

Change-Id: Ic66e9f872c57545327a9fb4b8ae86fbf0abbd8be
2016-09-22 21:26:23 -04:00
Alex Schultz
223c88460b Add in rspec-puppet-facts support
This change pulls in rspec-puppet-facts to provide the basic default
facts for puppet-tripleo rspec tests. rspec-puppet-facts provides an
easy to use interface to allow for the same set of tests to be executed
with multiple sets of operating system facts. In most cases this
includes defaults for Debian/RedHat based systems. In puppet-tripleo's
case this is just RHEL/CentOS. We are removing the Fedora listing from
the metadata.json as we only support RHEL and CentOS for tripleo.
This change also updates the existing rspec tests to leverage
rspec-puppet-facts to be more consistent with how facts are defined.

Change-Id: I0ddc71799d74ee95b9828aea6a8dcb4abb4e4e62
2016-09-21 17:34:55 -06:00
Emilien Macchi
70d23fb4b2 Revert "Pin puppetlabs_spec_helper to 1.1.1"
This reverts commit 8f8860c0343b49b50b3d0259b9c4a859f5d81cc3.

Change-Id: I456c3a46a16a904042b5af6c5fbe347912d1bf30
2016-08-24 01:50:03 +00:00
Emilien Macchi
8f8860c034 Pin puppetlabs_spec_helper to 1.1.1
Version 1.2.0 of puppetlabs_spec_helper pulled in a version gem with
ruby 2.2 requirements.
TripleO CI has ruby 2.0 so we need to pin the gem.

Change-Id: Idc3959e16aa329c1dfc335b766f52cd9dbde5de5
2016-08-23 16:18:51 -04:00
Emilien Macchi
5071c769fa Revert "Pin puppet-lint-absolute_classname-check to 0.1.3"
This reverts commit b546ad26fbdc98e6ae09d41b2ab2982db4c55135.
Bug was fixed, see:
https://github.com/voxpupuli/puppet-lint-absolute_classname-check/releases/tag/0.2.2

Change-Id: I95727fa7763064ab06bbccead9bf80d913863b5d
2016-06-23 08:25:11 -04:00
Emilien Macchi
b546ad26fb Pin puppet-lint-absolute_classname-check to 0.1.3
https://github.com/voxpupuli/puppet-lint-absolute_classname-check/issues/6

Change-Id: Ie6b69aef23c2028ad8632038a9a8283f4c1b8d40
2016-06-22 22:38:44 -04:00
Emilien Macchi
b5001ceca4 Drop webmock dependency
webmock is not used anywhere in puppet-tripleo, let's clean it.

Change-Id: Idd8646e69e31a63791a345765c459d094a23f813
2016-01-22 09:03:03 -05:00
Jaume Devesa
b94e93d8c8 Adding psych on Gemfile explicitly
It seems like bundle has a bug[1] that, somehow, it unloads the psych
library unless is installed through bundle itself. It will be fixed on
bundle 1.2.

[1]: http://github.com/bundler/bundler/issues/2068

Change-Id: Ic2fa8a8f114c3183a656bfdb1bc2d6d6413dbb75
2015-12-14 15:02:25 +01:00
Cody Herriges
e879bb6070 Initial msync run for all Puppet OpenStack modules
This patch is the initial modulesync run, it impacts:

* gitignore: just a sync between projects
* gemfile:
  - update and allow to setup facter version and gem source
  - split beaker gems with a dedicated group
  - switch to rspec-puppet 2.2.0
* rakefile:
  - use the new syntax for lint configuration
  - add a acceptance target
* acceptance:
  - sync nodesets
  - update tests in order to use zuul-cloner
* spec: added rspec coverage report

Change-Id: Iadefbe2cc0525224e9917c6712712c67ce1e0fff
2015-08-18 14:30:54 +02:00
Emilien Macchi
d6405961b4 Bump rspec-puppet to 2.1.0
rspec-puppet 2.1.0 includes Puppet 4.0 support [1].

[1] https://github.com/rodjek/rspec-puppet/commits/v2.1.0

Change-Id: I101785506c7f450c3a6146eee1e76ead28933e7a
2015-04-22 23:58:03 -04:00
Gael Chamoulaud
23c01f6e71 spec: updates for rspec-puppet 2.x and rspec 3.x
- This patch aim to update our specs test in order to work with the
  rspec-puppet release 2.0.0, in the mean time, we update rspec syntax order
  to be prepared for rspec 3.x move.

Change-Id: If67d5d39d7b94785c811a16703cdfe9782df2d24
Signed-off-by: Gael Chamoulaud <gchamoul@redhat.com>
2015-03-17 10:34:29 +01:00
Gael Chamoulaud
653d7dcb13 Add Puppet 4.x lint checks
- This changes the puppet-lint requirement to 1.1.x, so that we can use
  puppet-lint plugins. Most of these plugins are for 4.x compat, but some just
  catch common errors.

Change-Id: I2660b960b6ef696bd5dc8a6965b4a9aa25409b66
Signed-off-by: Gael Chamoulaud <gchamoul@redhat.com>
2015-03-17 10:23:32 +01:00
Emilien Macchi
37ddc04170 Add basic structure for a Puppet module 2015-02-02 11:39:21 -05:00