diff --git a/test/functional/doc_controller_test.rb b/test/functional/doc_controller_test.rb index 03abd98..35ba553 100644 --- a/test/functional/doc_controller_test.rb +++ b/test/functional/doc_controller_test.rb @@ -59,11 +59,4 @@ class DocControllerTest < ActionController::TestCase get :topic, :section => 'user', :topic => 'accepting-friends' end - should 'bail out gracefully for unexisting sections or topics' do - assert_nothing_raised do - get :section, :section => 'something-very-unlikely' - get :section, :section => 'something-very-unlikely', :topic => 'other-thing-very-unlikely' - end - end - end diff --git a/test/integration/online_doc_test.rb b/test/integration/online_doc_test.rb new file mode 100644 index 0000000..4cf1124 --- /dev/null +++ b/test/integration/online_doc_test.rb @@ -0,0 +1,15 @@ +require "#{File.dirname(__FILE__)}/../test_helper" + +class OnlineDocTest < ActionController::IntegrationTest + + def test_404_section + get '/doc/something-very-unlikely' + assert_response 404 + end + + def test_404_topic + get '/doc/something-very-unlikely/unexisting-topic' + assert_response 404 + end + +end -- libgit2 0.21.2