diff options
Diffstat (limited to 'src/beautifulsoup/tests/test_tree.py')
-rw-r--r-- | src/beautifulsoup/tests/test_tree.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/beautifulsoup/tests/test_tree.py b/src/beautifulsoup/tests/test_tree.py index 1e87be0..191ec59 100644 --- a/src/beautifulsoup/tests/test_tree.py +++ b/src/beautifulsoup/tests/test_tree.py @@ -1,3 +1,4 @@ +# -*- coding: utf-8 -*- """Tests for Beautiful Soup's tree traversal methods. The tree traversal methods are the main advantage of using Beautiful @@ -33,6 +34,14 @@ class TreeTest(SoupTest): self.assertEqual([tag['id'] for tag in tags], should_match) +class TestFind(TreeTest): + """Basic tests of the find() method.""" + + def test_unicode_text_find(self): + soup = self.soup(u'<h1>Räksmörgås</h1>') + self.assertEqual(soup.find(text=u'Räksmörgås'), u'Räksmörgås') + + class TestFindAll(TreeTest): """Basic tests of the findAll() method.""" |