Sha256: dc86eba75b07eaeabf3e100c49548dbbeec7166a2b28f323ddc2f149e147df73
Contents?: true
Size: 766 Bytes
Versions: 8
Compression:
Stored size: 766 Bytes
Contents
require File.expand_path('spec/helper') require "Bacon_Colored" require 'Checked' shared :ruby_dsl do before { extend Checked::DSL::Ruby } end shared :racked_dsl do before { extend Checked::DSL::Racked } end FOLDER = ("/tmp/Checked_Test") %x! mkdir -p #{FOLDER}! at_exit { %x! rm -rf #{FOLDER} ! } def ruby_e cmd file = "#{FOLDER}/delete_me_perf_#{rand(100000)}.rb" begin loader = File.expand_path( File.dirname(__FILE__) + '/../lib' ) File.open(file, 'w') { |io| io.write %~ $LOAD_PATH.unshift('#{loader}') #{cmd} ~ } %x[ bundle exec ruby #{file} 2>&1].strip ensure File.delete file end end Dir.glob('spec/tests/*.rb').each { |file| require File.expand_path(file.sub('.rb', '')) if File.file?(file) }
Version data entries
8 entries across 8 versions & 1 rubygems