Sha256: 20ed164593c784dd9ffcab1ee0aa374b5f74d29a762e47d0524e1b1f86c9bf64
Contents?: true
Size: 659 Bytes
Versions: 36
Compression:
Stored size: 659 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + "/../spec_helper") describe "Basic Auth HTTP headers" do before do basic_auth('user', 'secret') end it "should be present in visit" do webrat_session.should_receive(:get).with("/", {}, {'HTTP_AUTHORIZATION' => "Basic dXNlcjpzZWNyZXQ=\n"}) visit("/") end it "should be present in form submits" do with_html <<-HTML <html> <form method="post" action="/form1"> <input type="submit" /> </form> </html> HTML webrat_session.should_receive(:post).with("/form1", {}, {'HTTP_AUTHORIZATION' => "Basic dXNlcjpzZWNyZXQ=\n"}) click_button end end
Version data entries
36 entries across 36 versions & 15 rubygems