Sha256: 2cb021c571986b8c5832c76671f00bb982524577c31d6bea712ce34b37933f88
Contents?: true
Size: 793 Bytes
Versions: 24
Compression:
Stored size: 793 Bytes
Contents
require "lib/builders/spec_helper" describe SC::Builder::Handlebars do include SC::SpecHelpers include SC::BuilderSpecHelper before do std_before :handlebars_test # add fake image entry for sc_static tests.. @manifest.add_entry 'icons/image.png' end after do std_after end def run_builder(filename) super do |entry, dst_path| SC::Builder::Handlebars.build(entry, dst_path) end end it "converts Handlebars to JavaScript" do lines = run_builder 'templates/template.handlebars' lines[0].should =~ /SC\.TEMPLATES\["template"\] =/ end it "handles sc_static" do lines = run_builder 'templates/template.handlebars' lines[0].should include('<img src=\\"/static/handlebars_test/en/current/icons/image.png?0\\" />') end end
Version data entries
24 entries across 24 versions & 1 rubygems