summaryrefslogtreecommitdiff
path: root/test/rake/test_rake_file_utils.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/rake/test_rake_file_utils.rb')
-rw-r--r--test/rake/test_rake_file_utils.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/test/rake/test_rake_file_utils.rb b/test/rake/test_rake_file_utils.rb
index 90565e3..37d33dc 100644
--- a/test/rake/test_rake_file_utils.rb
+++ b/test/rake/test_rake_file_utils.rb
@@ -44,15 +44,19 @@ class TestRakeFileUtils < Rake::TestCase
class BadLink
include Rake::FileUtilsExt
attr_reader :cp_args
+
def initialize(klass)
@failure_class = klass
end
+
def cp(*args)
@cp_args = args
end
+
def ln(*args)
fail @failure_class, "ln not supported"
end
+
public :safe_ln
end
@@ -94,7 +98,7 @@ class TestRakeFileUtils < Rake::TestCase
assert_equal true, nowrite
nowrite false
assert_equal false, nowrite
- nowrite(true){
+ nowrite(true) {
assert_equal true, nowrite
}
assert_equal false, nowrite
@@ -250,7 +254,7 @@ class TestRakeFileUtils < Rake::TestCase
assert_equal ['..', 'a', 'b'], Rake::FileUtilsExt.split_all('../a/b')
end
- def command name, text
+ def command(name, text)
open name, 'w', 0750 do |io|
io << text
end