require_relative "../lib/jstgenerator"
describe JstGenerator::Handlebars do
jst_path = "spec/fixtures/handlebars/jst.js"
after(:each) do
File.delete(jst_path) if File.exist?(jst_path)
end
it "creates the JST file with the correct content" do
hb = JstGenerator::Handlebars.new({
:dir_glob => "spec/fixtures/handlebars/*.hb",
:jst_path => jst_path
}).generate
content = IO.read(jst_path)
expect(content).to eq(<