context 'set everything' do
let(:facts) do
{
+ :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},
:lsbdistid => 'Ubuntu',
:osfamily => 'Debian',
:lsbdistcodename => 'trusty',
describe 'mint tests' do
let(:facts) do
{
+ :os => { :family => 'Debian', :name => 'Linuxmint', :release => { :major => '17', :full => '17' }},
:lsbdistid => 'linuxmint',
:osfamily => 'Debian',
:lsbdistcodename => 'qiana',
describe 'validation' do
let(:facts) do
{
+ :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},
:lsbdistid => 'Ubuntu',
:osfamily => 'Debian',
:lsbdistcodename => 'trusty',
it do
expect {
subject.call
- }.to raise_error(Puppet::Error, /expects a String value/)
+ }.to raise_error(Puppet::Error, /expects a/)
end
end
context 'invalid release' do
it do
expect {
subject.call
- }.to raise_error(Puppet::Error, /expects a String value/)
+ }.to raise_error(Puppet::Error, /expects a/)
end
end
context 'invalid repos' do
it do
expect {
subject.call
- }.to raise_error(Puppet::Error, /expects a String value/)
+ }.to raise_error(Puppet::Error, /expects a/)
end
end
context 'invalid key' do
it do
expect {
subject.call
- }.to raise_error(Puppet::Error, /expects a value of type String, Hash,/)
+ }.to raise_error(Puppet::Error, /expects a/)
end
end
context 'invalid pin' do
it do
expect {
subject.call
- }.to raise_error(Puppet::Error, /parameter 'pin' expects a value of type Integer, Pattern/)
+ }.to raise_error(Puppet::Error, /expects a/)
end
end
end