spec/lib/server_spec.rb in doorkeeper-2.1.4 vs spec/lib/server_spec.rb in doorkeeper-2.2.0
- old
+ new
@@ -23,10 +23,12 @@
end.to raise_error(Doorkeeper::Errors::InvalidTokenStrategy)
end
context 'when only Authorization Code strategy is enabled' do
before do
- Doorkeeper.configuration.stub(:grant_flows) { ['authorization_code'] }
+ allow(Doorkeeper.configuration).
+ to receive(:grant_flows).
+ and_return(['authorization_code'])
end
it 'raises error when using the disabled Implicit strategy' do
expect do
subject.authorization_request(:token)