Merge branch 'sk-dont-redirect-to-images'

This commit is contained in:
Shane Kilkelly
2017-05-17 09:48:16 +01:00
2 changed files with 13 additions and 1 deletions
@@ -555,6 +555,14 @@ describe "AuthenticationController", ->
@AuthenticationController._setRedirectInSession(@req, '/somewhere/specific')
expect(@req.session.postLoginRedirect).to.equal "/somewhere/specific"
describe 'with a png', ->
beforeEach ->
@req = {session: {}}
it 'should not set the redirect', ->
@AuthenticationController._setRedirectInSession(@req, '/something.png')
expect(@req.session.postLoginRedirect).to.equal undefined
describe 'with a js path', ->
beforeEach ->