You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
339 B
Ruby
19 lines
339 B
Ruby
require 'test/unit'
|
|
require 'htree/extract_text'
|
|
require 'htree/equality'
|
|
|
|
class TestExtractText < Test::Unit::TestCase
|
|
def test_single
|
|
n = HTree::Text.new('abc')
|
|
assert_equal(n, n.extract_text)
|
|
end
|
|
|
|
def test_elem
|
|
t = HTree::Text.new('abc')
|
|
n = HTree::Elem.new('e', t)
|
|
assert_equal(t, n.extract_text)
|
|
end
|
|
|
|
|
|
end
|