Sha256: 77ff49f6dadefe8b7ef7cda8185d829fb2ac135ce055732615e4e9f6203d6ef6
Contents?: true
Size: 891 Bytes
Versions: 21
Compression:
Stored size: 891 Bytes
Contents
require 'spec_helper' describe Request do let(:request_url) { "url" } let(:trigger_url) { "trigger url" } let(:body) { "body" } let(:parameters) { {"name" => "joe"} } let(:headers) { {"header" => "value"} } let(:request_json) do {body: body, headers: headers, parameters: parameters, request_url: trigger_url} end it 'delete a request' do request_url = "url" Request.should_receive(:delete).with(request_url) request = Request.new request.request_url = request_url request.delete end it 'should load request data' do Request.should_receive(:backedup_get).with(request_url, format: :json).and_return(request_json) request = Request.get(request_url) request.headers.should == headers request.body.should == body request.request_url.should == trigger_url request.parameters.should == parameters end end
Version data entries
21 entries across 21 versions & 1 rubygems