aboutsummaryrefslogtreecommitdiffstats
path: root/test/scanf/test_scanfblocks.rb
diff options
context:
space:
mode:
authordblack <dblack@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-03-02 11:21:32 +0000
committerdblack <dblack@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-03-02 11:21:32 +0000
commit760691ca01f6785fa7c63a0a51dca04b82a2fc37 (patch)
tree01110ddab32c8b0cc54c70039ed3465651cc88e5 /test/scanf/test_scanfblocks.rb
parent5aad8206044f98b28bc303d5bd7d3e4f935e96ec (diff)
downloadruby-760691ca01f6785fa7c63a0a51dca04b82a2fc37.tar.gz
Fixed to work with Ruby test suite (patch from Nobu)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5873 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/scanf/test_scanfblocks.rb')
-rw-r--r--test/scanf/test_scanfblocks.rb11
1 files changed, 6 insertions, 5 deletions
diff --git a/test/scanf/test_scanfblocks.rb b/test/scanf/test_scanfblocks.rb
index 6b9945a159..861c36a5a6 100644
--- a/test/scanf/test_scanfblocks.rb
+++ b/test/scanf/test_scanfblocks.rb
@@ -5,11 +5,10 @@
# Some not very comprehensive tests of block behavior.
-$:.unshift("..")
require 'test/unit'
-require 'scanf.rb'
+require 'scanf'
-class TestMe < Test::Unit::TestCase
+class TestScanfBlock < Test::Unit::TestCase
def setup
@str = <<-EOS
@@ -61,7 +60,8 @@ alias set_up setup
"Scarlatti was born in 1685.",
"Brahms was born in 1833." ],res)
fh.close
-# File.delete("iotest.dat")
+ ensure
+ File.delete("iotest.dat")
end
def test_io2
@@ -71,7 +71,8 @@ alias set_up setup
fh.seek(0)
assert_equal(fh.scanf("%d%f%s") {}, [])
fh.close
- # File.delete("iotest.dat")
+ ensure
+ File.delete("iotest.dat")
end
end