summaryrefslogtreecommitdiff
path: root/lib/chef/provider
diff options
context:
space:
mode:
authorJohn Keiser <john@johnkeiser.com>2015-06-01 18:09:45 -0700
committerJohn Keiser <john@johnkeiser.com>2015-06-02 09:53:41 -0700
commit871848fe20769ca8ebf54632f278cc508b5c26aa (patch)
tree98327c777bcdeba2933bbff11e945685840d400e /lib/chef/provider
parentcd7617fcf5fa45149de934c29abc54d9e8bb4d28 (diff)
downloadchef-871848fe20769ca8ebf54632f278cc508b5c26aa.tar.gz
Create tests for all previous provider_mappingsjk/one_map_to_rule_them_all
Diffstat (limited to 'lib/chef/provider')
-rw-r--r--lib/chef/provider/group/suse.rb2
-rw-r--r--lib/chef/provider/group/usermod.rb1
-rw-r--r--lib/chef/provider/mount.rb2
-rw-r--r--lib/chef/provider/mount/mount.rb2
-rw-r--r--lib/chef/provider/package.rb14
5 files changed, 11 insertions, 10 deletions
diff --git a/lib/chef/provider/group/suse.rb b/lib/chef/provider/group/suse.rb
index 370cbe8492..b47ea33e80 100644
--- a/lib/chef/provider/group/suse.rb
+++ b/lib/chef/provider/group/suse.rb
@@ -22,7 +22,7 @@ class Chef
class Provider
class Group
class Suse < Chef::Provider::Group::Groupadd
- provides :group, platform: 'opensuse'
+ provides :group, platform: 'opensuse', platform_version: '< 12.3'
provides :group, platform: 'suse', platform_version: '< 12.0'
def load_current_resource
diff --git a/lib/chef/provider/group/usermod.rb b/lib/chef/provider/group/usermod.rb
index fee97e05a4..d78d42d6e1 100644
--- a/lib/chef/provider/group/usermod.rb
+++ b/lib/chef/provider/group/usermod.rb
@@ -24,6 +24,7 @@ class Chef
class Usermod < Chef::Provider::Group::Groupadd
provides :group, os: %w(openbsd solaris2 hpux)
+ provides :group, platform: "opensuse"
def load_current_resource
super
diff --git a/lib/chef/provider/mount.rb b/lib/chef/provider/mount.rb
index 6e8e077eaf..2039e9ae51 100644
--- a/lib/chef/provider/mount.rb
+++ b/lib/chef/provider/mount.rb
@@ -24,8 +24,6 @@ require 'chef/provider'
class Chef
class Provider
class Mount < Chef::Provider
- provides :mount
-
include Chef::Mixin::ShellOut
attr_accessor :unmount_retries
diff --git a/lib/chef/provider/mount/mount.rb b/lib/chef/provider/mount/mount.rb
index 0a6e269d2d..ef074166a9 100644
--- a/lib/chef/provider/mount/mount.rb
+++ b/lib/chef/provider/mount/mount.rb
@@ -24,6 +24,8 @@ class Chef
class Mount
class Mount < Chef::Provider::Mount
+ provides :mount
+
def initialize(new_resource, run_context)
super
@real_device = nil
diff --git a/lib/chef/provider/package.rb b/lib/chef/provider/package.rb
index 29ca3005a5..291ff882f6 100644
--- a/lib/chef/provider/package.rb
+++ b/lib/chef/provider/package.rb
@@ -512,15 +512,15 @@ class Chef
Chef.set_provider_priority_array :package, Apt, platform_family: "debian"
Chef.set_provider_priority_array :package, Yum, platform_family: %w(rhel fedora)
Chef.set_provider_priority_array :package, Zypper, platform_family: "suse"
- Chef.set_provider_priority_array :package, Portage, platform: %w(gentoo)
- Chef.set_provider_priority_array :package, Pacman, platform: %w(arch)
+ Chef.set_provider_priority_array :package, Portage, platform: "gentoo"
+ Chef.set_provider_priority_array :package, Pacman, platform: "arch"
Chef.set_provider_priority_array :package, Ips, platform: %w(openindiana opensolaris omnios solaris2)
- Chef.set_provider_priority_array :package, Solaris, platform: %w(nexentacore)
- Chef.set_provider_priority_array :package, Solaris, platform: %w(solaris2), platform_version: '< 5.11'
+ Chef.set_provider_priority_array :package, Solaris, platform: "nexentacore"
+ Chef.set_provider_priority_array :package, Solaris, platform: "solaris2", platform_version: '< 5.11'
- Chef.set_provider_priority_array :package, SmartOS, platform: %w(smartos)
- Chef.set_provider_priority_array :package, Aix, platform: %w(aix)
- Chef.set_provider_priority_array :package, Paludis, platform: %w(exherbo)
+ Chef.set_provider_priority_array :package, SmartOS, platform: "smartos"
+ Chef.set_provider_priority_array :package, Aix, platform: "aix"
+ Chef.set_provider_priority_array :package, Paludis, platform: "exherbo"
end
end
end