spec/lib/server_spec.rb in doorkeeper-5.2.0.rc2 vs spec/lib/server_spec.rb in doorkeeper-5.2.0.rc3
- old
+ new
@@ -8,16 +8,10 @@
subject do
described_class.new
end
describe ".authorization_request" do
- it "raises error when strategy does not exist" do
- expect do
- subject.authorization_request(:duh)
- end.to raise_error(Doorkeeper::Errors::InvalidAuthorizationStrategy)
- end
-
it "raises error when strategy does not match phase" do
expect do
subject.token_request(:code)
end.to raise_error(Doorkeeper::Errors::InvalidTokenStrategy)
end
@@ -25,15 +19,9 @@
context "when only Authorization Code strategy is enabled" do
before do
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)
- end.to raise_error(Doorkeeper::Errors::InvalidAuthorizationStrategy)
end
it "raises error when using the disabled Client Credentials strategy" do
expect do
subject.token_request(:client_credentials)