X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=spec%2Funit%2Fpuppet%2Ftype%2Fapt_key_spec.rb;h=0e9aaa2fd5dfc11caf9c74387d7bc79604b49c80;hb=559787268aa19c7c3f01d9597392bddfe5162a97;hp=c29f82b08862529c3e328cde6734bca4cff3c927;hpb=8fa73ac96fda8af4360e71b41c0a3e514f28080a;p=puppet-modules%2Fpuppetlabs-apt.git diff --git a/spec/unit/puppet/type/apt_key_spec.rb b/spec/unit/puppet/type/apt_key_spec.rb index c29f82b..0e9aaa2 100644 --- a/spec/unit/puppet/type/apt_key_spec.rb +++ b/spec/unit/puppet/type/apt_key_spec.rb @@ -82,7 +82,7 @@ describe Puppet::Type::type(:apt_key) do resource[:source].should eq 'http://apt.puppetlabs.com/pubkey.gpg' end end - + context 'with content' do let(:resource) { Puppet::Type.type(:apt_key).new( :id => '4BD6EC30', @@ -93,7 +93,7 @@ describe Puppet::Type::type(:apt_key) do resource[:content].should eq 'http://apt.puppetlabs.com/pubkey.gpg' end end - + context 'with keyserver' do let(:resource) { Puppet::Type.type(:apt_key).new( :id => '4BD6EC30', @@ -143,6 +143,13 @@ describe Puppet::Type::type(:apt_key) do )}.to_not raise_error end + it 'allows the https URI with username and password' do + expect { Puppet::Type.type(:apt_key).new( + :id => '4BD6EC30', + :source => 'https://testme:Password2@pgp.mit.edu' + )}.to_not raise_error + end + it 'allows the ftp URI scheme in source' do expect { Puppet::Type.type(:apt_key).new( :id => '4BD6EC30',