Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix acceptance tests #1250

Merged
merged 2 commits into from
May 7, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions spec/acceptance/06_postgresql_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@

describe 'postgresql datastore', if: RSpec.configuration.sensu_mode == 'full' do
node = hosts_as('sensu-backend')[0]
before do
if ! RSpec.configuration.sensu_test_enterprise
skip("Skipping postgresql tests")
end
end
context 'adds postgresql datastore' do
it 'should work without errors and be idempotent' do
pp = <<-EOS
Expand Down
6 changes: 3 additions & 3 deletions spec/acceptance/99_facts_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@

it "should have backend facts" do
version = on(backend, 'facter -p sensu_backend.version').stdout
expect(version).to match(/^[0-9\.]+$/)
expect(version).to match(/^[0-9\.]+/)
end

it "should have sensuctl facts" do
version = on(backend, 'facter -p sensuctl.version').stdout
expect(version).to match(/^[0-9\.]+$/)
expect(version).to match(/^[0-9\.]+/)
end
end

Expand All @@ -54,7 +54,7 @@

it "should have agent facts" do
version = on(agent, 'facter -p sensu_agent.version').stdout
expect(version).to match(/^[0-9\.]+$/)
expect(version).to match(/^[0-9\.]+/)
end
end
end
5 changes: 0 additions & 5 deletions spec/acceptance/sensu_ad_auth_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@

describe 'sensu_ad_auth', if: RSpec.configuration.sensu_mode == 'types' do
node = hosts_as('sensu-backend')[0]
before do
if ! RSpec.configuration.sensu_test_enterprise
skip("Skipping enterprise tests")
end
end
context 'default' do
it 'should work without errors' do
pp = <<-EOS
Expand Down
5 changes: 0 additions & 5 deletions spec/acceptance/sensu_ldap_auth_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@

describe 'sensu_ldap_auth', if: RSpec.configuration.sensu_mode == 'types' do
node = hosts_as('sensu-backend')[0]
before do
if ! RSpec.configuration.sensu_test_enterprise
skip("Skipping enterprise tests")
end
end
context 'default' do
it 'should work without errors' do
pp = <<-EOS
Expand Down
5 changes: 0 additions & 5 deletions spec/acceptance/sensu_oidc_auth_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@

describe 'sensu_oidc_auth', if: RSpec.configuration.sensu_mode == 'types' do
node = hosts_as('sensu-backend')[0]
before do
if ! RSpec.configuration.sensu_test_enterprise
skip("Skipping enterprise tests")
end
end
context 'default' do
it 'should work without errors' do
pp = <<-EOS
Expand Down
5 changes: 0 additions & 5 deletions spec/acceptance/sensu_secrets_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@

describe 'sensu_secrets_vault_provider', if: RSpec.configuration.sensu_mode == 'types' do
node = hosts_as('sensu-backend')[0]
before do
if ! RSpec.configuration.sensu_test_enterprise
skip("Skipping enterprise tests")
end
end
context 'default' do
it 'should work without errors' do
pp = <<-EOS
Expand Down
2 changes: 1 addition & 1 deletion spec/spec_helper_acceptance.rb
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
if collection == 'puppet6'
on setup_nodes, puppet('module', 'install', 'puppetlabs-yumrepo_core', '--version', '">= 1.0.1 < 2.0.0"'), { :acceptable_exit_codes => [0,1] }
end
if RSpec.configuration.sensu_test_enterprise
if ['full','examples'].include?(RSpec.configuration.sensu_mode)
on setup_nodes, puppet('module', 'install', 'puppetlabs-postgresql', '--version', '">= 6.0.0 < 7.0.0"'), { :acceptable_exit_codes => [0,1] }
end
# Dependencies only needed to test some examples
Expand Down