Class: RspecN::Input

Inherits:
Object
  • Object
show all
Defined in:
lib/rspec_n/input.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options, args) ⇒ Input

Returns a new instance of Input.



5
6
7
8
9
10
11
12
13
14
15
16
17
18
# File 'lib/rspec_n/input.rb', line 5

def initialize(options, args)
  @args = args
  @unprocessed_args_array = args.entries
  @options = options
  @iterations = determine_iterations
  @spec_path = determine_spec_path
  validate_order
  @order = @options.fetch(:order, "rand")
  @command = determine_command
  @stop_fast = options.fetch(:"stop-fast", false)
  @write_files = !options.fetch(:'no-file', false)
  @timestamp = options.fetch(:timestamp, false)
  @log_path = determine_log_path
end

Instance Attribute Details

#commandObject

Returns the value of attribute command.



3
4
5
# File 'lib/rspec_n/input.rb', line 3

def command
  @command
end

#iterationsObject

Returns the value of attribute iterations.



3
4
5
# File 'lib/rspec_n/input.rb', line 3

def iterations
  @iterations
end

#log_pathObject

Returns the value of attribute log_path.



3
4
5
# File 'lib/rspec_n/input.rb', line 3

def log_path
  @log_path
end

#stop_fastObject

Returns the value of attribute stop_fast.



3
4
5
# File 'lib/rspec_n/input.rb', line 3

def stop_fast
  @stop_fast
end

#write_filesObject

Returns the value of attribute write_files.



3
4
5
# File 'lib/rspec_n/input.rb', line 3

def write_files
  @write_files
end

Instance Method Details

#write_files?Boolean

Returns:

  • (Boolean)


20
21
22
# File 'lib/rspec_n/input.rb', line 20

def write_files?
  @write_files
end