Class: Jasmine::Headless::Task

Inherits:
Object
  • Object
show all
Includes:
Rake::DSL
Defined in:
lib/jasmine/headless/task.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name = 'jasmine:headless') {|_self| ... } ⇒ Task

Returns a new instance of Task.

Yields:

  • (_self)

Yield Parameters:



8
9
10
11
12
13
14
15
16
17
18
19
# File 'lib/jasmine/headless/task.rb', line 8

def initialize(name = 'jasmine:headless')
  @colors = false
  @keep_on_error = false
  @jasmine_config = nil

  yield self if block_given?

  desc 'Run Jasmine specs headlessly'
  task(name) { run_rake_task }

  create_rails_compliant_task if defined?(Rails)
end

Instance Attribute Details

#colorsObject

Returns the value of attribute colors.



6
7
8
# File 'lib/jasmine/headless/task.rb', line 6

def colors
  @colors
end

#jasmine_configObject

Returns the value of attribute jasmine_config.



6
7
8
# File 'lib/jasmine/headless/task.rb', line 6

def jasmine_config
  @jasmine_config
end

#keep_on_errorObject

Returns the value of attribute keep_on_error.



6
7
8
# File 'lib/jasmine/headless/task.rb', line 6

def keep_on_error
  @keep_on_error
end