Sha256: 1f63b41b47f6e9b1420d7626a2c7a7b42e885e628daae9a4b6bb96d962c6bfc9

Contents?: true

Size: 567 Bytes

Versions: 5

Compression:

Stored size: 567 Bytes

Contents

# encoding: utf-8
require 'spec_helper'

describe Workbench::HamlRenderer do

  before do
    @root = File.dirname(__FILE__) + '/fixtures'
  end

  it 'HAML файл' do
    result = Workbench::HamlRenderer.render "#{@root}/index.haml"
    result.should == "<h1 style=\"color: red\" title=\"&amp;\">Hello world!</h1>\n"
  end

  it 'файл с опциями' do
    result = Workbench::HamlRenderer.render "#{@root}/index.haml", { :attr_wrapper => "'", :escape_attrs => false }
    result.should == "<h1 style='color: red' title='&'>Hello world!</h1>\n"
  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
work-bench-1.0.12 spec/haml_renderer_spec.rb
work-bench-1.0.11 spec/haml_renderer_spec.rb
work-bench-1.0.10 spec/haml_renderer_spec.rb
work-bench-1.0.9 spec/haml_renderer_spec.rb
work-bench-1.0.8 spec/haml_renderer_spec.rb