require 'spec_helper' describe OmniAuth::Strategies::Accounts9 do let(:request) { double('Request', :params => {}, :cookies => {}, :env => {}) } subject do args = ['appid', 'secret', @options || {}].compact OmniAuth::Strategies::Accounts9.new(*args).tap do |strategy| strategy.stub(:request) { request } end end describe 'client options' do it 'should have correct name' do expect(subject.options.name).to eq('accounts9') end it 'should have correct site' do expect(subject.options.client_options.site).to eq('https://accounts.net9.org') end it 'should have correct authorize url' do expect(subject.options.client_options.authorize_path).to eq('/api/authorize') end end end