Top Level Namespace

Includes:
RestBaby, WebMock::API

Defined Under Namespace

Modules: RestBaby Classes: MockRestService

Constant Summary

DEFAULT_MSG =
'{"Answer": "What did you expect?"}'
DEFAULT_RESPONSE =
'{"Question": "What is the meaning of life?"}'

Constants included from RestBaby

RestBaby::VERSION

Instance Method Summary (collapse)

Instance Method Details

- (Object) create_get(path, message = DEFAULT_MSG)



32
33
34
35
36
37
38
39
# File 'features/step_definitions/rest_client_steps.rb', line 32

def create_get(path, message = DEFAULT_MSG)
  @path = path.split('?')[0]
  if path.split('?').length == 1
    @mockservice.store_msg('GET', @path, message.to_s)
  else
    @mockservice.store_get_query(path)
  end
end

- (Object) pause



1
2
3
4
# File 'features/support/utility.rb', line 1

def pause
  print 'Press Return to continue...'
  STDIN.getc
end