Skip to content

Commit

Permalink
install dependencies in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
bastelfreak committed Oct 28, 2022
1 parent a3f624c commit 724657a
Showing 1 changed file with 21 additions and 22 deletions.
43 changes: 21 additions & 22 deletions spec/acceptance/class_spec.rb
Expand Up @@ -4,29 +4,28 @@

describe 'vault class' do
context 'default parameters' do
# Using puppet_apply as a helper
it 'works idempotently with no errors' do
pp = <<-MANIFEST
package { 'unzip': ensure => present }
-> class { 'vault':
storage => {
file => {
path => '/tmp',
}
},
listener => [{
tcp => {
address => '127.0.0.1:8200',
tls_disable => 1,
}
}]
}
MANIFEST
# Run it twice and test for idempotency
apply_manifest(pp, catch_failures: true)
apply_manifest(pp, catch_changes: true)
it_behaves_like 'an idempotent resource' do
let(:manifest) do
<<-PUPPET
include file_capability
package { 'unzip': ensure => present }
-> class { 'vault':
storage => {
file => {
path => '/tmp',
}
},
listener => [{
tcp => {
address => '127.0.0.1:8200',
tls_disable => 1,
}
}],
require => Class['file_capability'],
}
PUPPET
end
end

# rubocop:disable RSpec/RepeatedExampleGroupBody
describe user('vault') do
it { is_expected.to exist }
Expand Down

0 comments on commit 724657a

Please sign in to comment.