Sha256: 9d9884b304ef6151a57688c98fbc9e1d2dc7af5c78a9e4e5a4d422f7f207807b
Contents?: true
Size: 675 Bytes
Versions: 26
Compression:
Stored size: 675 Bytes
Contents
module CcApiStub module Login class << self def succeeds_to_find_uaa(domain="http://some-other-random-domain.com:8181") WebMock::API.stub_request(:get, "#{domain}/info"). to_return( :status => 200, :body => "{\"authorization_endpoint\":\"https://uaa.localhost\"}" ) end def succeeds_to_login_as_admin WebMock::API.stub_request(:post, %r{uaa.localhost/oauth/authorize}). to_return( :status => 302, :headers => {"Location" => "https://uaa.localhost/redirect/vmc#access_token=sre-admin-access-token&token_type=bearer"} ) end end end end
Version data entries
26 entries across 26 versions & 3 rubygems