diff --git a/test/functional/iqdb_queries_controller_test.rb b/test/functional/iqdb_queries_controller_test.rb index a9dd869f1..2e6cba454 100644 --- a/test/functional/iqdb_queries_controller_test.rb +++ b/test/functional/iqdb_queries_controller_test.rb @@ -28,6 +28,13 @@ class IqdbQueriesControllerTest < ActionController::TestCase assert_response :success end + + should "render for a json response" do + mock_iqdb_matches!(@posts[0].source, @posts) + get :index, { url: @posts[0].source, format: "json" }, { user_id: @user.id } + + assert_response :success + end end end end