From 9df17f5a8bcf80a2e2c0f00126347becbcc2f15e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Thu, 5 Sep 2013 10:42:17 +0200 Subject: add spesc for Node#no_view! --- spec/node_spec.rb | 5 +++++ spec/spec_helper.rb | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/spec/node_spec.rb b/spec/node_spec.rb index 061c6a5..3b2ecc3 100644 --- a/spec/node_spec.rb +++ b/spec/node_spec.rb @@ -257,6 +257,11 @@ describe Zorglub do r.header['Content-type'].should == 'text/plain' end # + it "no view no layout should work as well" do + r = Node0.my_call '/no_view_no_layout' + r.body[0].should == "hello world" + end + # it "haml engine should work" do Node0.app.opt! :engines_cache_enabled, false r = Node0.my_call '/engines/haml' diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 5ff5dfb..2f5b3ac 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -76,6 +76,11 @@ class Node0 < Zorglub::Node ext! 'txt' mime! 'text/plain' end + def no_view_no_layout + no_view! + no_layout! + 'hello world' + end def engines name no_layout! case name -- cgit v1.1-2-g2b99