mirror of
https://github.com/sinatra/sinatra
synced 2023-03-27 23:18:01 -04:00
Resolve test name conflict
In AfterFilterTest in filter_test.rb there are two tests named "executes filters in the order defined", causing the first not to be run. Rename the first test, and fix the mock app in the test so it doesn't cause a Rack::Lint error.
This commit is contained in:
parent
1c36d54778
commit
1950d202c6
1 changed files with 2 additions and 2 deletions
|
@ -156,11 +156,11 @@ class BeforeFilterTest < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
class AfterFilterTest < Test::Unit::TestCase
|
||||
it "executes filters in the order defined" do
|
||||
it "executes before and after filters in correct order" do
|
||||
invoked = 0
|
||||
mock_app do
|
||||
before { invoked = 2 }
|
||||
get('/') { invoked += 2 }
|
||||
get('/') { invoked += 2; 'hello' }
|
||||
after { invoked *= 2 }
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue