diff --git a/etc/deprecations.json b/etc/deprecations.json index d0eb84cac..6d61f13f6 100644 --- a/etc/deprecations.json +++ b/etc/deprecations.json @@ -83,11 +83,6 @@ "suffix": "This resource was removed in InSpec 4.0.", "comment": "Needed for ServerSpec compatibility" }, - "resource_ppa": { - "action": "exit", - "suffix": "This resource was removed in InSpec 4.0.", - "comment": "Needed for ServerSpec compatibility" - }, "resource_script": { "action": "exit", "suffix": "This resource will be removed in InSpec 4.0" diff --git a/lib/inspec/resources/apt.rb b/lib/inspec/resources/apt.rb index acc3996cb..1abb9151c 100644 --- a/lib/inspec/resources/apt.rb +++ b/lib/inspec/resources/apt.rb @@ -135,19 +135,25 @@ module Inspec::Resources class PpaRepository < AptRepository name "ppa" + desc "Use the ppa InSpec audit resource to verify PPA repositories on the Debian-based linux platforms." + example <<~EXAMPLE + describe ppa('ubuntu-wine/ppa') do + it { should exist } + it { should be_enabled } + end + + describe ppa('ppa:ubuntu-wine/ppa') do + it { should exist } + it { should be_enabled } + end + EXAMPLE def exists? - deprecated super() end def enabled? - deprecated super() end - - def deprecated - Inspec.deprecate(:resource_ppa, "The `ppa` resource is deprecated. Please use `apt`") - end end end