summaryrefslogtreecommitdiffstats
path: root/test/ral
diff options
context:
space:
mode:
authorluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2007-03-08 07:09:42 +0000
committerluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2007-03-08 07:09:42 +0000
commitb6df3369bc8a1dadfab2c7baa6d4572785c075fb (patch)
tree78c91084dd33aa0cda93a9ea459c6881c4e1f7b7 /test/ral
parent0925fb0cd9b7d370a57247b00f402d33f6f0d78b (diff)
Looks like [2265] was not a complete solution -- it resulted in failures when the config set modes via integers. Everything is working now, and tested more completely.
git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2268 980ebf18-57e1-0310-9a29-db15c13687c0
Diffstat (limited to 'test/ral')
-rwxr-xr-xtest/ral/types/file.rb18
1 files changed, 11 insertions, 7 deletions
diff --git a/test/ral/types/file.rb b/test/ral/types/file.rb
index 647b1e185..c9ba6d835 100755
--- a/test/ral/types/file.rb
+++ b/test/ral/types/file.rb
@@ -31,11 +31,11 @@ class TestFile < Test::Unit::TestCase
super
@file = Puppet::Type.type(:file)
$method = @method_name
- begin
- initstorage
- rescue
- system("rm -rf %s" % Puppet[:statefile])
- end
+# begin
+# initstorage
+# rescue
+# system("rm -rf %s" % Puppet[:statefile])
+# end
end
def teardown
@@ -1009,12 +1009,16 @@ class TestFile < Test::Unit::TestCase
:ensure => "file",
:mode => "0777"
)
+ assert_equal(0777, file.should(:mode),
+ "Mode did not get set correctly")
assert_apply(file)
- assert_equal(0777, File.stat(path).mode & 007777)
+ assert_equal(0777, File.stat(path).mode & 007777,
+ "file mode is incorrect")
File.unlink(path)
file[:ensure] = "directory"
assert_apply(file)
- assert_equal(0777, File.stat(path).mode & 007777)
+ assert_equal(0777, File.stat(path).mode & 007777,
+ "directory mode is incorrect")
end
def test_followlinks