aboutsummaryrefslogtreecommitdiff
path: root/spec/spec_helper_acceptance.rb
diff options
context:
space:
mode:
authorJacob Helwig <jacob@technosorcery.net>2018-06-28 14:47:37 -0700
committerJacob Helwig <jacob@technosorcery.net>2018-07-02 10:22:13 -0700
commitd33a751bd3cc8f5c99dd9953f09f0ed2ee3ad58f (patch)
treef0a8495b5ee01c72622fe78669d6d5ee0e038212 /spec/spec_helper_acceptance.rb
parent620b0d9b0e085953347919822bc9513d048f6be9 (diff)
downloadpuppet-sshkeys_core-d33a751bd3cc8f5c99dd9953f09f0ed2ee3ad58f.tar.gz
puppet-sshkeys_core-d33a751bd3cc8f5c99dd9953f09f0ed2ee3ad58f.tar.bz2
Update acceptance tests to use RSpec syntax
Diffstat (limited to 'spec/spec_helper_acceptance.rb')
-rw-r--r--spec/spec_helper_acceptance.rb26
1 files changed, 26 insertions, 0 deletions
diff --git a/spec/spec_helper_acceptance.rb b/spec/spec_helper_acceptance.rb
new file mode 100644
index 0000000..ac6b27e
--- /dev/null
+++ b/spec/spec_helper_acceptance.rb
@@ -0,0 +1,26 @@
+require 'beaker-rspec'
+require 'beaker/module_install_helper'
+require 'beaker/puppet_install_helper'
+
+def beaker_opts
+ { debug: true, trace: true, expect_failures: true, acceptable_exit_codes: (0...256) }
+ # { expect_failures: true, acceptable_exit_codes: (0...256) }
+end
+
+def posix_agents
+ agents.reject { |agent| agent['platform'].include?('windows') }
+end
+
+def osx_agents
+ agents.select { |agent| agent['platform'].include?('osx') }
+end
+
+RSpec.configure do |c|
+ c.before :suite do
+ unless ENV['BEAKER_provision'] == 'no'
+ run_puppet_install_helper
+ install_module_on(hosts_as('default'))
+ install_module_dependencies_on(hosts)
+ end
+ end
+end