Codebase list ruby-omniauth-twitter / 5a81ed6
Merge pull request #86 from liftcode/master Fixed support for skip_info option to ensure raw_info isn't called Rashmi Yadav 9 years ago
2 changed file(s) with 11 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
2626 end
2727
2828 extra do
29 { :raw_info => raw_info }
29 skip_info? ? {} : { :raw_info => raw_info }
3030 end
3131
3232 def raw_info
5252 end
5353 end
5454
55 describe 'skip_info option' do
56 context 'when skip info option is enabled' do
57 it 'should not include raw_info in extras hash' do
58 @options = { :skip_info => true }
59 allow(subject).to receive(:raw_info).and_return({:foo => 'bar'})
60 expect(subject.extra[:raw_info]).to eq(nil)
61 end
62 end
63 end
64
5565 describe 'request_phase' do
5666 context 'with no request params set and x_auth_access_type specified' do
5767 before do