module StartingBlocks class MinitestContract < Contract def file_clues ["_test", "test_", "_spec"] end def extensions ['.rb'] end def filter_these_files files files.select { |x| options[:include_vendor] || x.include?('/vendor/') == false } end def execute_these_files files requires = files.map { |x| "require '#{x}'" }.join("\n") if options[:use_bundler] `bundle exec ruby -e "#{requires}"` else `ruby -e "#{requires}"` end end end end