spec/models/rspeed/splitter/actual_examples_spec.rb in rspeed-0.4.0 vs spec/models/rspeed/splitter/actual_examples_spec.rb in rspeed-0.5.0

- old
+ new

@@ -1,9 +1,7 @@ # frozen_string_literal: true -require 'rails_helper' - RSpec.describe RSpeed::Splitter, '#actual_examples' do it 'returns all examples' do splitter = described_class.new(specs_path: 'spec/fixtures/**/*_spec.rb') expect(splitter.actual_examples).to eq [ @@ -14,9 +12,15 @@ ] end it 'does not raise when no file match' do splitter = described_class.new(specs_path: 'spec/fixtures/**/*_missing.rb') + + expect(splitter.actual_examples).to eq [] + end + + it 'does not raise when file is empty' do + splitter = described_class.new(specs_path: 'spec/fixtures/**/empty.rb') expect(splitter.actual_examples).to eq [] end end