Sha256: e265484254f15e2d362ca97e5b471fb468b0f5b8e0b625a42c947eec12085bfd
Contents?: true
Size: 1.16 KB
Versions: 3
Compression:
Stored size: 1.16 KB
Contents
require 'spec_helper' describe Rubix::Connection do before do integration_test end after do truncate_all_tables end it "can perform an authorized GET request to the homepage" do response = Rubix.connection.web_request("GET", "/") response.should_not be_nil response.code.to_i.should == 200 response.body.should_not include('guest') response.body.should include($RUBIX_INTEGRATION_TEST['username']) end it "can perform an authorized POST request to the homepage" do response = Rubix.connection.web_request("POST", "/", :foo => 'bar', :baz => 'buzz') response.should_not be_nil response.code.to_i.should == 200 response.body.should_not include('guest') response.body.should include($RUBIX_INTEGRATION_TEST['username']) end it "can perform an authorized multipart POST request to the homepage" do response = Rubix.connection.web_request("POST", "/", :foo => File.new(data_path('test_template.xml'))) response.should_not be_nil response.code.to_i.should == 200 response.body.should_not include('guest') response.body.should include($RUBIX_INTEGRATION_TEST['username']) end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
rubix-0.4.3 | spec/requests/connection_request_spec.rb |
rubix-0.4.2 | spec/requests/connection_request_spec.rb |
rubix-0.4.1 | spec/requests/connection_request_spec.rb |