summaryrefslogtreecommitdiff
path: root/benchmark/bm_file_rename.rb
diff options
context:
space:
mode:
Diffstat (limited to 'benchmark/bm_file_rename.rb')
-rw-r--r--benchmark/bm_file_rename.rb11
1 files changed, 0 insertions, 11 deletions
diff --git a/benchmark/bm_file_rename.rb b/benchmark/bm_file_rename.rb
deleted file mode 100644
index 3bf6a5e..0000000
--- a/benchmark/bm_file_rename.rb
+++ /dev/null
@@ -1,11 +0,0 @@
-# rename file
-require 'tempfile'
-
-max = 100_000
-tmp = [ Tempfile.new('rename-a'), Tempfile.new('rename-b') ]
-a, b = tmp.map { |x| x.path }
-max.times do
- File.rename(a, b)
- File.rename(b, a)
-end
-tmp.each { |t| t.close! }