Sha256: 38a30f74250d3caa53c3540c12de57cc1d1ae1608db6ba7fccdb9a90b1c6c6dd

Contents?: true

Size: 668 Bytes

Versions: 16

Compression:

Stored size: 668 Bytes

Contents

require "spec_helper"

module Beaker
  module Options
    describe OptionsFileParser do
      let(:parser) { described_class }
      let(:simple_opts) { File.join(__dir__, "data", "opts.txt") }

      it "can correctly read options from a file" do
        FakeFS.deactivate!
        expect(parser.parse_options_file(simple_opts)).to be === { :debug => true, :tests => "test.rb", :pre_suite => ["pre-suite.rb"], :post_suite => "post_suite1.rb,post_suite2.rb" }
      end

      it "raises an error on no file found" do
        FakeFS.deactivate!
        expect { parser.parse_options_file("not a valid path") }.to raise_error(ArgumentError)
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
beaker-6.4.1 spec/beaker/options/options_file_parser_spec.rb
beaker-6.4.0 spec/beaker/options/options_file_parser_spec.rb
beaker-6.3.0 spec/beaker/options/options_file_parser_spec.rb
beaker-6.2.0 spec/beaker/options/options_file_parser_spec.rb
beaker-6.1.0 spec/beaker/options/options_file_parser_spec.rb
beaker-5.8.1 spec/beaker/options/options_file_parser_spec.rb
beaker-5.8.0 spec/beaker/options/options_file_parser_spec.rb
beaker-5.7.0 spec/beaker/options/options_file_parser_spec.rb
beaker-5.6.0 spec/beaker/options/options_file_parser_spec.rb
beaker-5.5.0 spec/beaker/options/options_file_parser_spec.rb
beaker-5.4.0 spec/beaker/options/options_file_parser_spec.rb
beaker-5.3.1 spec/beaker/options/options_file_parser_spec.rb
beaker-5.3.0 spec/beaker/options/options_file_parser_spec.rb
beaker-5.2.0 spec/beaker/options/options_file_parser_spec.rb
beaker-5.1.0 spec/beaker/options/options_file_parser_spec.rb
beaker-5.0.0 spec/beaker/options/options_file_parser_spec.rb