Merge pull request #21 from rdsoze/master
Test Cases added
Arun Agrawal
12 years ago
0 | 0 | require 'spec_helper' |
1 | 1 | |
2 | 2 | describe OmniAuth::Strategies::Twitter do |
3 | ||
4 | it 'should give the right options' do | |
5 | some_rack_app = double('app').as_null_object | |
6 | OmniAuth::Strategies::Twitter.new(some_rack_app).name.should == 'twitter' | |
3 | subject do | |
4 | OmniAuth::Strategies::Twitter.new({}) | |
7 | 5 | end |
8 | 6 | |
7 | context "client options" do | |
8 | it 'should have correct name' do | |
9 | subject.options.name.should eq("twitter") | |
10 | end | |
11 | ||
12 | it 'should have correct site' do | |
13 | subject.options.client_options.site.should eq('https://api.twitter.com') | |
14 | end | |
15 | ||
16 | it 'should have correct authorize url' do | |
17 | subject.options.client_options.authorize_path.should eq('/oauth/authenticate') | |
18 | end | |
19 | end | |
9 | 20 | end |