Sha256: ed6c3049240772ec4fa7c1bc983b947fd334cca50338468aae56f4f10996495a
Contents?: true
Size: 611 Bytes
Versions: 3
Compression:
Stored size: 611 Bytes
Contents
require "assert" require "undies/template" class Undies::Template class BuilderRenderTests < Assert::Context desc 'a template rendered using the builder approach' before do @src = Undies::Source.new(Proc.new {}) @io = Undies::IO.new(@out = "") @t = Undies::Template.new(@src, {}, @io) end subject { @t } should "maintain scope throughout the build blocks" do templ = Undies::Template.new(@io) templ._div { templ._div self.object_id } templ.__flush assert_equal "<div><div>#{self.object_id}</div></div>", @out end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
undies-3.0.0.rc.3 | test/template_builder_render_test.rb |
undies-3.0.0.rc.2 | test/template_builder_render_test.rb |
undies-3.0.0.rc.1 | test/template_builder_render_test.rb |