Sha256: ab925fddaeb5fc25ac56f17f5f26967e7d013537911dc30bab2031547212db2d

Contents?: true

Size: 843 Bytes

Versions: 1

Compression:

Stored size: 843 Bytes

Contents

module Lucid
  class Context
    def self.default
      new
    end

    def self.parse(argument)
      return new(argument) if argument.is_a?(Hash)
      argument
    end

    def initialize(user_options = {})
      @options = default_options.merge(user_options)
    end

    def dry_run?
      @options[:dry_run]
    end

    def guess?
      @options[:guess]
    end

    def strict?
      @options[:strict]
    end

    def expand?
      @options[:expand]
    end

    def spec_source
      @options[:spec_source]
    end

    def autoload_code_paths
      @options[:autoload_code_paths]
    end

    def matcher_type
      @options[:matcher_type]
    end

  private

    def default_options
      {
        :autoload_code_paths => %w(features/support features/step_definitions features/steps common steps pages)
      }
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
lucid-0.5.1 lib/lucid/context.rb