Sha256: 8cd52e33d23ac3aea7df42aa7fedb71b0bb63af8b72d06998d0fcc0eca925182
Contents?: true
Size: 682 Bytes
Versions: 1
Compression:
Stored size: 682 Bytes
Contents
require_relative '../spec_helper' require 'wright/util/file_renderer' describe Wright::Util::FileRenderer do describe 'render' do before(:each) do @template_files = { 'foo.erb' => '<%= foo %>', 'foo.mustache' => '{{foo}}' } end after(:each) { FakeFS::FileSystem.clear } it 'should render template files' do renderer = Wright::Util::FileRenderer.new(foo: 'FOOBAR') FakeFS do @template_files.each do |filename, template| File.write(filename, template) expected = 'FOOBAR' actual = renderer.render(filename) actual.must_equal expected end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
wright-0.5.0 | spec/util/file_renderer_spec.rb |