Module: Cucumber::Pro

Defined in:
lib/cucumber/pro.rb,
lib/cucumber/pro/info.rb,
lib/cucumber/pro/errors.rb,
lib/cucumber/pro/formatter.rb,
lib/cucumber/pro/scm/working_copy.rb,
lib/cucumber/pro/web_socket/session.rb

Defined Under Namespace

Modules: Error, Scm, WebSocket Classes: Config, Formatter, Info

Class Method Summary collapse

Class Method Details

.configObject



28
29
30
# File 'lib/cucumber/pro.rb', line 28

def config
  @config ||= Config.new
end

.configure {|config| ... } ⇒ Object

Yields:



24
25
26
# File 'lib/cucumber/pro.rb', line 24

def configure
  yield config
end

.new(runtime, output, options) ⇒ Object



9
10
11
12
13
14
15
16
17
18
19
20
21
22
# File 'lib/cucumber/pro.rb', line 9

def new(runtime, output, options)
  create_logger(output)

  working_copy = Scm::WorkingCopy.detect

  if should_publish
    working_copy.check_clean if config.should_check_clean
    session = WebSocket::Session.new(url, logger, timeout: config.timeout)
  else
    session = WebSocket::NullSession.new
  end

  Formatter.new(session, working_copy)
end