Make the acceptance tests work
authorMorgan Haskel <morgan@puppetlabs.com>
Wed, 18 Mar 2015 19:56:29 +0000 (12:56 -0700)
committerMorgan Haskel <morgan@puppetlabs.com>
Wed, 18 Mar 2015 19:56:29 +0000 (12:56 -0700)
spec/acceptance/apt_key_provider_spec.rb
spec/acceptance/apt_spec.rb

index 24277d237ad60fcf392332e7eedc4b3e7d6d6a95..42fe19d2d63687d6332ed80d712761d4d51159ae 100644 (file)
@@ -488,14 +488,14 @@ ugVIB2pi+8u84f+an4Hml4xlyijgYu05pqNvnLRyJDLd61hviLC8GYU=
     end
   end
 
     end
   end
 
-  describe 'keyserver_options =>' do
+  describe 'options =>' do
     context 'debug' do
       it 'works' do
         pp = <<-EOS
         apt_key { 'puppetlabs':
     context 'debug' do
       it 'works' do
         pp = <<-EOS
         apt_key { 'puppetlabs':
-          id                => '#{PUPPETLABS_GPG_KEY_LONG_ID}',
-          ensure            => 'present',
-          keyserver_options => 'debug',
+          id      => '#{PUPPETLABS_GPG_KEY_LONG_ID}',
+          ensure  => 'present',
+          options => 'debug',
         }
         EOS
 
         }
         EOS
 
@@ -507,9 +507,9 @@ ugVIB2pi+8u84f+an4Hml4xlyijgYu05pqNvnLRyJDLd61hviLC8GYU=
       it 'fails on invalid options' do
         pp = <<-EOS
         apt_key { 'puppetlabs':
       it 'fails on invalid options' do
         pp = <<-EOS
         apt_key { 'puppetlabs':
-          id                => '#{PUPPETLABS_GPG_KEY_LONG_ID}',
-          ensure            => 'present',
-          keyserver_options => 'this is totally bonkers',
+          id      => '#{PUPPETLABS_GPG_KEY_LONG_ID}',
+          ensure  => 'present',
+          options => 'this is totally bonkers',
         }
         EOS
 
         }
         EOS
 
index e409a9098f4d8b93b1c9284cf905fc3434fc8307..cea4dcde0412a2155d1cc385c1487ee732120b6f 100644 (file)
@@ -12,21 +12,27 @@ describe 'apt class' do
     it 'should work with no errors' do
       pp = <<-EOS
       class { 'apt':
     it 'should work with no errors' do
       pp = <<-EOS
       class { 'apt':
-        always_apt_update    => true,
-        purge_sources_list   => true,
-        purge_sources_list_d => true,
-        purge_preferences    => true,
-        purge_preferences_d  => true,
-        update_timeout       => '400',
-        update_tries         => '3',
-        sources              => {
+        update => {
+          'frequency' => 'always',
+          'timeout'   => '400',
+          'tries'     => '3',
+        },
+        purge => {
+          'sources.list'   => true,
+          'sources.list.d' => true,
+          'preferences'    => true,
+          'preferences.d'  => true,
+        },
+        sources => {
           'puppetlabs' => {
           'puppetlabs' => {
-            'ensure'     => present,
-            'location'   => 'http://apt.puppetlabs.com',
-            'repos'      => 'main',
-            'key'        => '4BD6EC30',
-            'key_server' => 'pgp.mit.edu',
-          }
+            'ensure'   => present,
+            'location' => 'http://apt.puppetlabs.com',
+            'repos'    => 'main',
+            'key'      => {
+              'id'     => '4BD6EC30',
+              'server' => 'pgp.mit.edu',
+            },
+          },
         },
       }
       EOS
         },
       }
       EOS