Sha256: aab9cca6c744a5c71ff36823b1ed52db979356f57755049916090d0764c2694c
Contents?: true
Size: 812 Bytes
Versions: 9
Compression:
Stored size: 812 Bytes
Contents
# encoding: UTF-8 require 'trac-wiki' require 'pp' require 'bacon' #class Bacon::Context #end describe 'TracWiki::Parser' do it 'should work' do t = TracWiki::Tree.new t.tag_beg(:div, {:class => 'html'}) t.tag_beg(:div, {id:'JAN', class: nil}) t.tag(:div, {:class => "ahoj", id: "BHOJ"}) t.tag(:br) t.add("bye") t.add_spc t.add("bye ") t.add_spc t.add("bye") t.tag_end(:div) t.tag_end(:div) t.add('\bye') t.add_raw('>') t.add_raw(' ') t.add_raw('„') res = "<div class=\"html\"><div id=\"JAN\"><div class=\"ahoj\" id=\"BHOJ\"></div>\n<br/>bye bye bye</div>\n</div>\n\\bye" res += ">" #res += "\u00a0" #res += "„" res += ' ' res += '„' #print "\n#{t.to_html}\n#{res}" t.to_html.should.equal res end end
Version data entries
9 entries across 9 versions & 1 rubygems