Fix test cases
- Remove duplicate tests - use parse_html helper
This commit is contained in:
parent
9f71b1ec7b
commit
9c8dd60f92
|
@ -31,20 +31,16 @@ describe Oga::XML::Parser do
|
||||||
|
|
||||||
context 'void elements with different casing' do
|
context 'void elements with different casing' do
|
||||||
before :all do
|
before :all do
|
||||||
@node_lc = parse('<br>', html: true).children[0]
|
@node_uc = parse_html('<BR>').children[0]
|
||||||
@node_uc = parse('<BR>', html: true).children[0]
|
|
||||||
end
|
end
|
||||||
|
|
||||||
example 'parse void elements with different casing' do
|
example 'parse void elements with different casing' do
|
||||||
@node_lc.is_a?(Oga::XML::Element).should == true
|
|
||||||
@node_uc.is_a?(Oga::XML::Element).should == true
|
@node_uc.is_a?(Oga::XML::Element).should == true
|
||||||
end
|
end
|
||||||
|
|
||||||
example 'set the name of the void element to match casing' do
|
example 'set the name of the void element to match casing' do
|
||||||
@node_lc.name.should == 'br'
|
|
||||||
@node_uc.name.should == 'BR'
|
@node_uc.name.should == 'BR'
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
context 'void elements with attributes' do
|
context 'void elements with attributes' do
|
||||||
|
|
Loading…
Reference in New Issue