New Puppet version somewhat changed error message, so update tests

This commit is contained in:
Kevin Paulisse 2018-02-28 15:35:41 -06:00
Родитель 8f78fe87e5
Коммит cd6eba5270
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 66DA91D838188671
1 изменённых файлов: 5 добавлений и 5 удалений

Просмотреть файл

@ -129,7 +129,7 @@ describe 'validation of references in computed catalog' do
if OctocatalogDiff::Spec.is_puppet5? if OctocatalogDiff::Spec.is_puppet5?
it 'should pass through the error messages from Puppet' do it 'should pass through the error messages from Puppet' do
msg = @result.exception.message msg = @result.exception.message
expect(msg).to match(/Error: Could not find resource 'Exec\[subscribe target\]' in parameter 'subscribe' at/) expect(msg).to match(/Error: Could not find resource 'Exec\[subscribe target\]' in parameter 'subscribe'/)
end end
else else
# Multiple line numbers given because Puppet 4.x and 3.8 correspond to first and last line of resource, respectively. # Multiple line numbers given because Puppet 4.x and 3.8 correspond to first and last line of resource, respectively.
@ -162,7 +162,7 @@ describe 'validation of references in computed catalog' do
if OctocatalogDiff::Spec.is_puppet5? if OctocatalogDiff::Spec.is_puppet5?
it 'should pass through the error messages from Puppet' do it 'should pass through the error messages from Puppet' do
msg = @result.exception.message msg = @result.exception.message
expect(msg).to match(/Error: Could not find resource 'Exec\[before target\]' in parameter 'before' at/) expect(msg).to match(/Error: Could not find resource 'Exec\[before target\]' in parameter 'before'/)
end end
else else
# rubocop:disable Metrics/LineLength # rubocop:disable Metrics/LineLength
@ -190,7 +190,7 @@ describe 'validation of references in computed catalog' do
if OctocatalogDiff::Spec.is_puppet5? if OctocatalogDiff::Spec.is_puppet5?
it 'should pass through the error messages from Puppet' do it 'should pass through the error messages from Puppet' do
msg = @result.exception.message msg = @result.exception.message
expect(msg).to match(/Error: Could not find resource 'Test::Foo::Bar\[notify target\]' in parameter 'notify' at/) expect(msg).to match(/Error: Could not find resource 'Test::Foo::Bar\[notify target\]' in parameter 'notify'/)
end end
else else
# rubocop:disable Metrics/LineLength # rubocop:disable Metrics/LineLength
@ -218,7 +218,7 @@ describe 'validation of references in computed catalog' do
if OctocatalogDiff::Spec.is_puppet5? if OctocatalogDiff::Spec.is_puppet5?
it 'should pass through the error messages from Puppet' do it 'should pass through the error messages from Puppet' do
msg = @result.exception.message msg = @result.exception.message
expect(msg).to match(/Error: Could not find resource 'Exec\[require target\]' in parameter 'require' at/) expect(msg).to match(/Error: Could not find resource 'Exec\[require target\]' in parameter 'require'/)
end end
else else
# rubocop:disable Metrics/LineLength # rubocop:disable Metrics/LineLength
@ -246,7 +246,7 @@ describe 'validation of references in computed catalog' do
it 'should pass through the error messages from Puppet' do it 'should pass through the error messages from Puppet' do
msg = @result.exception.message msg = @result.exception.message
expect(msg).to match(/Error: Could not find resource 'Exec\[subscribe target\]' in parameter 'subscribe' at/) expect(msg).to match(/Error: Could not find resource 'Exec\[subscribe target\]' in parameter 'subscribe'/)
end end
else else
it 'should succeed' do it 'should succeed' do