Sha256: 570a7e70b15de23c88771195d70a1a09b68f78d2a347564349b101ab0129348b

Contents?: true

Size: 604 Bytes

Versions: 8

Compression:

Stored size: 604 Bytes

Contents

require 'test_helper'

class ParserTest < Test::Unit::TestCase
  context "A Parser instance" do

    context "with config file and core-externals loaded and the -f'format' option set" do

      setup do
        AbsoluteRenamer::External.load_core

        AbsoluteRenamer::Config.load('conf/absrenamer/absrenamer.conf')
        ARGV << '-f'
        ARGV << 'format'
      end

      should "be able to parse the format from the command line options" do
        AbsoluteRenamer::Parser.parse_cmd_line
        assert_equal('format', AbsoluteRenamer::Config[:options][:format])
      end

    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
AbsoluteRenamer-1.1.2 test/parser_test.rb
AbsoluteRenamer-1.1.1 test/parser_test.rb
AbsoluteRenamer-1.1.0 test/parser_test.rb
AbsoluteRenamer-1.0.4 test/parser_test.rb
AbsoluteRenamer-1.0.3 test/parser_test.rb
AbsoluteRenamer-1.0.2 test/parser_test.rb
AbsoluteRenamer-1.0.1 test/parser_test.rb
AbsoluteRenamer-1.0.0 test/parser_test.rb