summaryrefslogtreecommitdiff
path: root/test/ruby/test_argf.rb
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-06-02 10:18:38 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-06-02 10:18:38 +0000
commit8a5dd664e7dd66f63fdf7bf7b6ff2fdef715db3a (patch)
tree48fe0783a6e48228516a491c94b6c13c16790206 /test/ruby/test_argf.rb
parenteaa3ffbae8f20ddae208747db5310b113ffbbf71 (diff)
* test/ruby/test_argf.rb (teardown): remove renamed temporary files.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16755 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_argf.rb')
-rw-r--r--test/ruby/test_argf.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/ruby/test_argf.rb b/test/ruby/test_argf.rb
index 8280e5e5068..695b6f21962 100644
--- a/test/ruby/test_argf.rb
+++ b/test/ruby/test_argf.rb
@@ -18,6 +18,14 @@ class TestArgf < Test::Unit::TestCase
@t3.puts "5"
@t3.puts "6"
@t3.close
+ @tmps = [@t1, @t2, @t3]
+ end
+
+ def teardown
+ @tmps.each {|t|
+ bak = t.path + ".bak"
+ File.unlink bak if File.file? bak
+ }
end
def make_tempfile
@@ -26,6 +34,7 @@ class TestArgf < Test::Unit::TestCase
t.puts "bar"
t.puts "baz"
t.close
+ @tmps << t
t
end