aboutsummaryrefslogtreecommitdiffstats
path: root/test/test_tempfile.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/test_tempfile.rb')
-rw-r--r--test/test_tempfile.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/test_tempfile.rb b/test/test_tempfile.rb
index 8147d93f85..cd2828df37 100644
--- a/test/test_tempfile.rb
+++ b/test/test_tempfile.rb
@@ -345,5 +345,14 @@ puts Tempfile.new('foo').path
f.close if f && !f.closed?
File.unlink path if path
end
+
+ def test_create_default_basename
+ path = nil
+ Tempfile.create {|f|
+ path = f.path
+ assert_file.exist?(path)
+ }
+ assert_file.not_exist?(path)
+ end
end