File tree Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -271,16 +271,25 @@ def post_xml(xml = :example_response, opts = {})
271271 end
272272
273273 describe 'POST /auth/saml/slo' do
274+ subject { post "/auth/saml/slo" , params , opts }
275+
274276 before do
275277 saml_options [ :sp_entity_id ] = "https://idp.sso.example.com/metadata/29490"
276278 end
277279
278280 context "when response is a logout response" do
279- before :each do
280- post "/auth/saml/slo" , {
281+ let ( :params ) do
282+ {
281283 SAMLResponse : load_xml ( :example_logout_response ) ,
282284 RelayState : "https://example.com/" ,
283- } , "rack.session" => { "saml_transaction_id" => "_3fef1069-d0c6-418a-b68d-6f008a4787e9" }
285+ }
286+ end
287+ let ( :opts ) do
288+ "rack.session" => { "saml_transaction_id" => "_3fef1069-d0c6-418a-b68d-6f008a4787e9" }
289+ end
290+
291+ before :each do
292+ subject
284293 end
285294
286295 it "should redirect to relaystate" do
You can’t perform that action at this time.
0 commit comments