test/integration/command_test.rb in cogy-0.1.1 vs test/integration/command_test.rb in cogy-0.2.0
- old
+ new
@@ -4,20 +4,10 @@
class CommandTest < ActionDispatch::IntegrationTest
include Engine.routes.url_helpers
setup { @routes = Engine.routes }
- def test_error_tmpl_message
- get "/cogy/cmd/raiser/george"
- assert response.body.include?("boom")
- end
-
- def test_error_tmpl_contenttype
- get "/cogy/cmd/raiser/george"
- assert_equal "text/plain", response.content_type.to_s
- end
-
def test_error_response_code
get "/cogy/cmd/raiser/george"
assert_equal 500, response.status
end
@@ -50,8 +40,13 @@
1
end
end
assert_match(/\[:type, :required\]/, exception.message)
+ end
+
+ def test_args_ordering
+ get "/cogy/cmd/args_order/george", cog_argv_2: 3, cog_argv_1: 2, cog_argv_0: 1
+ assert_equal "123", response.body
end
end
end