From 677d37ee4cadd7991636aa43fa3919b1a8a9c619 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Tue, 3 Jan 2012 23:54:48 +0100 Subject: spec: add Node#view spec --- spec/node_spec.rb | 4 ++++ spec/spec_helper.rb | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/spec/node_spec.rb b/spec/node_spec.rb index 8d910a3..e6b6543 100644 --- a/spec/node_spec.rb +++ b/spec/node_spec.rb @@ -116,6 +116,10 @@ describe Zorglub do Node0.partial(:do_partial, 1, 2).should == "view_content" end # + it "method level view should work" do + Node0.partial(:other_view).should == "view_content" + end + # end # end diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index fef8cd5..43c8af2 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -52,6 +52,10 @@ class Node0 < Zorglub::Node def do_partial a1, a2 engine 'real' end + def other_view + engine 'real' + view 'do_partial' + end end # class Node1 < Zorglub::Node -- cgit v1.1-2-g2b99