Sha256: 48a0eb5bc3fca62f0fbf6eef8998c85efc672129510593bb96fc5d7774e59958
Contents?: true
Size: 1 KB
Versions: 1
Compression:
Stored size: 1 KB
Contents
require 'spec_helper' module RevealCK describe HamlProcessor do it 'can convert haml to html' do p = HamlProcessor.new "%p hi" p.html.should =~ %r{<p>hi</p>} end describe '.open' do let :abs_haml_file do spec_dir = File.expand_path(File.join(__FILE__, '..', '..', '..')) File.join spec_dir, 'data', 'haml', 'basic.haml' end let :rel_haml_file do 'spec/data/haml/basic.haml' end let :html_version do spec_dir = File.expand_path(File.join(__FILE__, '..', '..', '..')) html = File.join spec_dir, 'data', 'html', 'converted_basic_haml.html' File.open(html).read end it 'converts an entire file via absolute path' do processor = HamlProcessor.open abs_haml_file processor.html.should == html_version end it 'converts an entire file via relative path' do processor = HamlProcessor.open rel_haml_file processor.html.should == html_version end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
reveal-ck-0.1.3 | spec/lib/reveal-ck/haml_processor_spec.rb |