Sha256: 61304b70188edc5b45a1ff4ca1028e3d35f858b054b7d9b3c515239a46a76626
Contents?: true
Size: 1.02 KB
Versions: 1
Compression:
Stored size: 1.02 KB
Contents
require 'pathname' require 'rubygems' require 'spec/autorun' require Pathname(__FILE__).dirname.expand_path.join('..', 'lib', 'yardstick') Pathname.glob(Yardstick::ROOT.join('lib', '**', '*.rb').to_s).sort.each do |file| require file.to_s.chomp('.rb') end Spec::Runner.configure do |config| clear_tasks = lambda { Rake::Task.clear } config.before(:all, &clear_tasks) config.before( &clear_tasks) clear_yard_registry = lambda { YARD::Registry.clear } config.before(:all, &clear_yard_registry) config.before( &clear_yard_registry) def capture_stdout $stdout = StringIO.new yield ensure $stdout.rewind @output = $stdout.read $stdout = STDOUT end end shared_examples_for 'measured itself' do it 'should return a MeasurementSet' do @measurements.should be_kind_of(Yardstick::MeasurementSet) end it 'should be non-empty' do @measurements.should_not be_empty end it 'should all be correct' do @measurements.each { |measurement| measurement.should be_ok } end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
yardstick-0.1.0 | spec/spec_helper.rb |