summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Szalay <nicolas.szalay@fotolia.com>2014-10-16 10:40:54 +0200
committerNicolas Szalay <nicolas.szalay@fotolia.com>2014-10-16 10:40:54 +0200
commit9aa5caccf2220b747071debfc0f9b2d2eba72568 (patch)
tree5e26423ef694dfc9bb13057c6233049e0890f86a
parentdc0d9824bfe4af9d24c1ed5e72ad4a1e74c6d0cd (diff)
downloadchef-9aa5caccf2220b747071debfc0f9b2d2eba72568.tar.gz
update tests : add cgroup and use a loop
-rw-r--r--spec/unit/provider/mount/mount_spec.rb16
1 files changed, 6 insertions, 10 deletions
diff --git a/spec/unit/provider/mount/mount_spec.rb b/spec/unit/provider/mount/mount_spec.rb
index d6f71bc613..abab7640c0 100644
--- a/spec/unit/provider/mount/mount_spec.rb
+++ b/spec/unit/provider/mount/mount_spec.rb
@@ -107,16 +107,12 @@ describe Chef::Provider::Mount::Mount do
lambda { @provider.load_current_resource();@provider.mountable? }.should raise_error(Chef::Exceptions::Mount)
end
- it "does not expect the device to exist for tmpfs" do
- @new_resource.fstype("tmpfs")
- @new_resource.device("whatever")
- lambda { @provider.load_current_resource();@provider.mountable? }.should_not raise_error
- end
-
- it "does not expect the device to exist for Fuse filesystems" do
- @new_resource.fstype("fuse")
- @new_resource.device("nilfs#xxx")
- lambda { @provider.load_current_resource();@provider.mountable? }.should_not raise_error
+ [ "tmpfs", "fuse", "cgroup" ].each do |fstype|
+ it "does not expect the device to exist for #{fstype}" do
+ @new_resource.fstype(fstype)
+ @new_resource.device("whatever")
+ lambda { @provider.load_current_resource();@provider.mountable? }.should_not raise_error
+ end
end
it "does not expect the device to exist if it's none" do