+ :osfamily => 'Debian',
+ :puppetversion => Puppet.version,
+ }
+ end
+
+ context 'with complex pin' do
+ let :params do
+ {
+ :location => 'hello.there',
+ :pin => { 'release' => 'wishwash',
+ 'explanation' => 'wishwash',
+ 'priority' => 1001, },
+ }
+ end
+
+ it { is_expected.to contain_apt__setting('list-my_source').with({
+ :ensure => 'present',
+ }).with_content(/hello.there wheezy main\n/)
+ }
+
+ it { is_expected.to contain_apt__pin('my_source').that_comes_before('Apt::Setting[list-my_source]').with({
+ :ensure => 'present',
+ :priority => 1001,
+ :explanation => 'wishwash',
+ :release => 'wishwash',
+ })