From 8f38cb82be7f1e65655f333ecd8f38335cfb3d56 Mon Sep 17 00:00:00 2001 From: Jordi Prats Date: Mon, 5 Aug 2019 13:20:05 +0200 Subject: [PATCH] some acceptance testing --- spec/acceptance/base_spec.rb | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/spec/acceptance/base_spec.rb b/spec/acceptance/base_spec.rb index 4c8d81b..591451f 100644 --- a/spec/acceptance/base_spec.rb +++ b/spec/acceptance/base_spec.rb @@ -10,12 +10,28 @@ class { 'eyplib': } + -> + + class { 'eyplib::setdescription': + description => 'ACCEPTANCE TESTING', + } + + -> + + class { 'eyplib::autobanner': } + EOF - # Run it twice and test for idempotency + # run several times - expect the 3rd run to be clean + expect(apply_manifest(pp).exit_code).to_not eq(1) expect(apply_manifest(pp).exit_code).to_not eq(1) expect(apply_manifest(pp).exit_code).to eq(0) end + describe file('/opt/eypconf/autobanner') do + it { should be_file } + its(:content) { should match 'ACCEPTANCE TESTING' } + end + end end