
Current puppet-ceph CI is broken for all functional jobs. I would like to restart from scratch the way we test the module. 1) centos7: deploy Jewel using buildlogs.centos.org repo CentOS SIG does not provide packaging to deploy the Jewel repository, let's install it by hand. 2) Remove RGW tests for now. We'll re-add them later, in a puppet-openstack-integration scenario. 3) Reset spec files to match with other Puppet OpenStack modules. 4) On CentOS, use systemd resource and not sysvinit. 5) Fix keyring idempotency with SElinux. Change-Id: Ie9ba521cdb4ac6823746d37bb5d1697e274e4119
36 lines
1.2 KiB
Ruby
36 lines
1.2 KiB
Ruby
# Load libraries from openstacklib here to simulate how they live together in a real puppet run (for provider unit tests)
|
|
$LOAD_PATH.push(File.join(File.dirname(__FILE__), 'fixtures', 'modules', 'openstacklib', 'lib'))
|
|
require 'puppetlabs_spec_helper/module_spec_helper'
|
|
require 'shared_examples'
|
|
|
|
require 'puppet-openstack_spec_helper/defaults'
|
|
require 'rspec-puppet-facts'
|
|
include RspecPuppetFacts
|
|
|
|
RSpec.configure do |c|
|
|
c.alias_it_should_behave_like_to :it_configures, 'configures'
|
|
c.alias_it_should_behave_like_to :it_raises, 'raises'
|
|
# TODO(aschultz): remove this after all tests converted to use OSDefaults
|
|
# instead of referencing @default_facts
|
|
c.before :each do
|
|
@default_facts = OSDefaults.get_facts
|
|
end
|
|
fixture_path = File.expand_path(File.join(File.dirname(__FILE__), 'fixtures'))
|
|
|
|
c.hiera_config = File.join(fixture_path, 'hieradata/hiera.yaml')
|
|
|
|
c.before(:all) do
|
|
data = YAML.load_file(c.hiera_config)
|
|
data[:yaml][:datadir] = File.join(fixture_path, 'hieradata')
|
|
File.open(c.hiera_config, 'w') do |f|
|
|
f.write data.to_yaml
|
|
end
|
|
end
|
|
|
|
c.after(:all) do
|
|
`git checkout -- #{c.hiera_config}`
|
|
end
|
|
end
|
|
|
|
at_exit { RSpec::Puppet::Coverage.report! }
|