summaryrefslogtreecommitdiff
path: root/test/functional/home_controller_test.rb
diff options
context:
space:
mode:
authorazul <azul@riseup.net>2016-08-19 10:40:37 +0000
committerazul <azul@riseup.net>2016-08-19 10:40:37 +0000
commit67302ca1986a66a6d278c34216ad33f4c65a018e (patch)
treed55e4c4dd3a6612e04e0fd40e736c8b6d4342762 /test/functional/home_controller_test.rb
parent44910c0909f28791fe6725fa76301e5111ece3b4 (diff)
parentfbad882075e745ab7afbe5f89c67544fb3c607c3 (diff)
Merge branch 'bugfix/send-406-on-unsupported-format' into 'develop'
Bugfix/send 406 on unsupported format See merge request !5
Diffstat (limited to 'test/functional/home_controller_test.rb')
-rw-r--r--test/functional/home_controller_test.rb16
1 files changed, 16 insertions, 0 deletions
diff --git a/test/functional/home_controller_test.rb b/test/functional/home_controller_test.rb
new file mode 100644
index 0000000..cafaac5
--- /dev/null
+++ b/test/functional/home_controller_test.rb
@@ -0,0 +1,16 @@
+require 'test_helper'
+
+class HomeControllerTest < ActionController::TestCase
+
+ def test_renders_okay
+ get :index
+ assert_response :success
+ end
+
+ def test_other_formats_trigger_406
+ assert_raises ActionController::UnknownFormat do
+ get :index, format: :xml
+ end
+ end
+
+end