spec/lib/hotcell/template_spec.rb in hotcell-0.2.0 vs spec/lib/hotcell/template_spec.rb in hotcell-0.3.0
- old
+ new
@@ -65,14 +65,14 @@
context 'complex tags test' do
specify { described_class.parse(<<-SOURCE
{{ for i, in: [1, 2, 3, 4] }}
{{ if i % 2 == 1 }}
- {{ i }}
+ {{ "number\#{i}" }}
{{ end if }}
{{ end for }}
SOURCE
- ).render.gsub(/[\s\n]+/, ' ').strip.should == '1 3' }
+ ).render.gsub(/[\s\n]+/, ' ').strip.should == 'number1 number3' }
specify { described_class.parse(<<-SOURCE
{{ for i, in: [1, 2, 3, 4] }}
{{ for j, in: [4, 3, 2, 1] }}
{{ i * j }}