spec/controller_spec.rb in nyara-0.1.pre.0 vs spec/controller_spec.rb in nyara-0.1.pre.1

- old
+ new

@@ -18,7 +18,21 @@ end assert_equal nil, AChildController.controller_name assert_equal 'll', AChildController.default_layout end + + context "argument validation" do + class DummyController < Controller + get '/' do + end + end + + it "#redirect_to checks first parameter" do + c = DummyController.new Ext.request_new + assert_raise ArgumentError do + c.redirect_to '/' + end + end + end end end