Sha256: 9bba3f4095ff7f1a2771c13cdb06952d1110812fe5c4d5cf6082af55849a5372

Contents?: true

Size: 567 Bytes

Versions: 6

Compression:

Stored size: 567 Bytes

Contents

require 'spec_helper'

describe TMS::IpawsAcknowledgement do

  it 'gets IPAWS acknowledgement from client' do
    client = double(:client)
    response_body = { "ACK" => "PONG" }
    ipaws_acknowledgement = TMS::IpawsAcknowledgement.new(client, '/ipaws/acknowledgement', {})
    ipaws_acknowledgement.client.should_receive('get').with(ipaws_acknowledgement.href).and_return(
      double('response', :status => 200, :body => response_body)
    )
    ipaws_acknowledgement.get.should == ipaws_acknowledgement
    ipaws_acknowledgement.ACK.should == "PONG"
  end

end

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
govdelivery-tms-0.8.0 spec/ipaws_acknowledgement_spec.rb
tms_client-0.6.0 spec/ipaws_acknowledgement_spec.rb
tms_client-0.5.4 spec/ipaws_acknowledgement_spec.rb
tms_client-0.5.3 spec/ipaws_acknowledgement_spec.rb
tms_client-0.5.2 spec/ipaws_acknowledgement_spec.rb
tms_client-0.5.1 spec/ipaws_acknowledgement_spec.rb