summaryrefslogtreecommitdiff
path: root/benchmark/dir_empty_p.yml
diff options
context:
space:
mode:
Diffstat (limited to 'benchmark/dir_empty_p.yml')
-rw-r--r--benchmark/dir_empty_p.yml8
1 files changed, 8 insertions, 0 deletions
diff --git a/benchmark/dir_empty_p.yml b/benchmark/dir_empty_p.yml
new file mode 100644
index 0000000..73e59be
--- /dev/null
+++ b/benchmark/dir_empty_p.yml
@@ -0,0 +1,8 @@
+benchmark:
+ dir_empty_p: |
+ require 'tmpdir'
+ max = 100_000
+ Dir.mktmpdir('bm_dir_empty_p') do |dir|
+ max.times { Dir.empty?(dir) }
+ end
+loop_count: 1