Skip to content

Commit

Permalink
Merge branch 'master' into 0.2.x
Browse files Browse the repository at this point in the history
  • Loading branch information
jodosha committed Dec 4, 2014
2 parents 885e3c0 + a7e482b commit 0152063
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ rvm:
- 2.1.2
- 2.1.3
- 2.1.4
- 2.1.5
- 2.2
- rbx-2

Expand All @@ -19,5 +20,4 @@ matrix:
- rvm: jruby-head
env: JRUBY_OPTS="--2.1"
allow_failures:
- rvm: 2.2
- rvm: jruby-head
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Lotus::Router.new do

redirect '/legacy', to: '/'

mount Api::App, to: '/api'
mount Api::App, at: '/api'

namespace 'admin' do
get '/users', to: Users::Index
Expand Down
9 changes: 8 additions & 1 deletion test/integration/showexceptions_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,16 @@
@app = Rack::MockRequest.new(builder)
end

it 'shows exceptions page' do
it 'shows textual exception stack trace by default' do
response = @app.get('/')

response.status.must_equal 500
response.body.must_match 'Lotus::Routing::EndpointNotFound'
end

it 'shows exceptions page (when requesting HTML)' do
response = @app.get('/', 'HTTP_ACCEPT' => 'text/html')

response.status.must_equal 500
response.body.must_match '<body>'
response.body.must_match 'Lotus::Routing::EndpointNotFound'
Expand Down

0 comments on commit 0152063

Please sign in to comment.