Sha256: 46675984a8e2248c2139195c56eb71e3e6df767775c748c4ccd23ee44e286b8e
Contents?: true
Size: 993 Bytes
Versions: 1
Compression:
Stored size: 993 Bytes
Contents
require 'pathname' require 'rubygems' require 'spec/autorun' require 'yard' require '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 = proc { Rake::Task.clear } config.before(:all, &clear_tasks) config.before( &clear_tasks) clear_yard_registry = proc { 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.6.0 | spec/spec_helper.rb |