Skip to content

Commit 6d7ca60

Browse files
committed
add tests for new implementation contrib
1 parent 2140b72 commit 6d7ca60

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

spec/unit/classes/server/contrib_spec.rb

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,37 @@
4343
is_expected.to contain_package('postgresql-contrib').with(tag: 'puppetlabs-postgresql')
4444
end
4545
end
46+
47+
describe 'on Gentoo' do
48+
let :facts do
49+
{
50+
os: {
51+
family: 'Gentoo',
52+
name: 'Gentoo',
53+
},
54+
}
55+
end
56+
57+
it 'postgresql-contrib should not be installed' do
58+
is_expected.to compile
59+
is_expected.not_to contain_package('postgresql-contrib')
60+
end
61+
end
62+
63+
describe 'on Debian' do
64+
let :facts do
65+
{
66+
os: {
67+
family: 'Debian',
68+
name: 'Debian',
69+
release: { 'full' => '8.0', 'major' => '8' },
70+
},
71+
}
72+
end
73+
74+
it 'postgresql-contrib should not be installed' do
75+
is_expected.to compile
76+
is_expected.not_to contain_package('postgresql-contrib')
77+
end
78+
end
4679
end

0 commit comments

Comments
 (0)