Package lxml :: Package tests :: Module test_elementtree :: Class _ETreeTestCaseBase |
[hide private]
[frames] | no frames]

# Class _ETreeTestCaseBase

source code

                   object --+
                            |
       unittest.case.TestCase --+
                                |
    common_imports.HelperTestCase --+
                                    |
                                   _ETreeTestCaseBase

Known Subclasses:
  - ETreeTestCase
  - , ElementTreeTestCase

Nested Classes | [hide private]
Inherited from `unittest.case.TestCase`: `failureException`

Instance Methods | [hide private]
XMLParser(self, **kwargs) | source code
test_element(self) | source code
test_simple(self) | source code
test_weird_dict_interaction(self) | source code
test_subelement(self) | source code
test_element_contains(self) | source code
test_element_indexing_with_text(self) | source code
test_element_indexing_with_text2(self) | source code
test_element_indexing_only_text(self) | source code
test_element_indexing_negative(self) | source code
test_elementtree(self) | source code
test_text(self) | source code
test_text_empty(self) | source code
test_text_other(self) | source code
test_text_escape_in(self) | source code
test_text_escape_out(self) | source code
test_text_escape_tostring(self) | source code
test_text_str_subclass(self) | source code
test_tail(self) | source code
test_tail_str_subclass(self) | source code
_test_del_tail(self) | source code
test_ElementTree(self) | source code
test_attrib(self) | source code
test_attrib_get(self) | source code
test_attrib_dict(self) | source code
test_attrib_copy(self) | source code
test_attrib_deepcopy(self) | source code
test_attributes_get(self) | source code
test_attrib_clear(self) | source code
test_attrib_set_clear(self) | source code
test_attrib_ns_clear(self) | source code
test_attrib_pop(self) | source code
test_attrib_pop_unknown(self) | source code
test_attrib_pop_default(self) | source code
test_attrib_pop_empty_default(self) | source code
test_attrib_pop_invalid_args(self) | source code
test_attribute_update_dict(self) | source code
test_attribute_update_sequence(self) | source code
test_attribute_update_iter(self) | source code
test_attribute_update_attrib(self) | source code
test_attribute_keys(self) | source code
test_attribute_keys2(self) | source code
test_attribute_items2(self) | source code
test_attribute_keys_ns(self) | source code
test_attribute_values(self) | source code
test_attribute_values_ns(self) | source code
test_attribute_items(self) | source code
test_attribute_items_ns(self) | source code
test_attribute_str(self) | source code
test_attribute_contains(self) | source code
test_attribute_set(self) | source code
test_attrib_as_attrib(self) | source code
test_attribute_iterator(self) | source code
test_attribute_manipulation(self) | source code
test_del_attribute_ns(self) | source code
test_del_attribute_ns_parsed(self) | source code
test_XML(self) | source code
test_XMLID(self) | source code
test_fromstring(self) | source code
test_fromstringlist(self) | source code
test_fromstringlist_characters(self) | source code
test_fromstringlist_single(self) | source code
test_iselement(self) | source code
test_iteration(self) | source code
test_iteration_empty(self) | source code
test_iteration_text_only(self) | source code
test_iteration_crash(self) | source code
test_iteration_reversed(self) | source code
test_iteration_subelement(self) | source code
test_iteration_del_child(self) | source code
test_iteration_double(self) | source code
test_itertext(self) | source code
test_itertext_child(self) | source code
test_findall(self) | source code
test_findall_ns(self) | source code
test_element_with_attributes_keywords(self) | source code
test_element_with_attributes(self) | source code
test_element_with_attributes_extra(self) | source code
test_element_with_attributes_extra_duplicate(self) | source code
test_element_with_attributes_ns(self) | source code
test_subelement_with_attributes(self) | source code
test_subelement_with_attributes_ns(self) | source code
test_write(self) | source code
test_write_method_html(self) | source code
test_write_method_text(self) | source code
test_write_fail(self) | source code
test_crash(self) | source code
test_write_ElementTreeDoctest(self) | source code
test_subelement_reference(self) | source code
test_set_text(self) | source code
test_set_text2(self) | source code
test_set_text_none(self) | source code
test_set_text_empty(self) | source code
test_tail1(self) | source code
test_tail_append(self) | source code
test_tail_set_twice(self) | source code
test_tail_set_none(self) | source code
test_extend(self) | source code
test_comment(self) | source code
test_comment_text(self) | source code
test_comment_whitespace(self) | source code
test_comment_nonsense(self) | source code
test_pi(self) | source code
test_processinginstruction(self) | source code
test_pi_nonsense(self) | source code
test_setitem(self) | source code
test_setitem2(self) | source code
test_setitem_replace(self) | source code
test_setitem_indexerror(self) | source code
test_setitem_tail(self) | source code
test_tag_write(self) | source code
test_tag_reset_ns(self) | source code
test_tag_reset_root_ns(self) | source code
test_tag_str_subclass(self) | source code
test_delitem(self) | source code
test_del_insert(self) | source code
test_del_setitem(self) | source code
test_del_setslice(self) | source code
test_replace_slice_tail(self) | source code
test_merge_namespaced_subtree_as_slice(self) | source code
test_delitem_tail(self) | source code
test_clear(self) | source code
test_clear_sub(self) | source code
test_clear_tail(self) | source code
test_insert(self) | source code
test_insert_beyond_index(self) | source code
test_insert_negative(self) | source code
test_insert_tail(self) | source code
test_remove(self) | source code
test_remove_ns(self) | source code
test_remove_nonexisting(self) | source code
test_remove_tail(self) | source code
_test_getchildren(self) | source code
test_makeelement(self) | source code
test_iter(self) | source code
test_getiterator(self) | source code
test_getiterator_empty(self) | source code
test_getiterator_filter(self) | source code
test_getiterator_filter_all(self) | source code
test_getiterator_filter_comment(self) | source code
test_getiterator_filter_pi(self) | source code
test_getiterator_with_text(self) | source code
test_getiterator_filter_with_text(self) | source code
test_getslice(self) | source code
test_getslice_negative(self) | source code
test_getslice_step(self) | source code
test_getslice_text(self) | source code
test_comment_getitem_getslice(self) | source code
test_delslice(self) | source code
test_delslice_negative1(self) | source code
test_delslice_negative2(self) | source code
test_delslice_step(self) | source code
test_delslice_step_negative(self) | source code
test_delslice_step_negative2(self) | source code
test_delslice_child_tail(self) | source code
test_delslice_tail(self) | source code
test_delslice_memory(self) | source code
test_setslice(self) | source code
test_setslice_all(self) | source code
test_setslice_all_empty(self) | source code
test_setslice_all_replace(self) | source code
test_setslice_all_replace_reversed(self) | source code
test_setslice_all_replace_reversed_ns1(self) | source code
test_setslice_all_replace_reversed_ns2(self) | source code
test_setslice_end(self) | source code
test_setslice_end_exact(self) | source code
test_setslice_single(self) | source code
test_setslice_tail(self) | source code
test_setslice_negative(self) | source code
test_setslice_negative2(self) | source code
test_setslice_empty(self) | source code
test_tail_elementtree_root(self) | source code
test_elementtree_getiterator(self) | source code
test_elementtree_getiterator_filter(self) | source code
test_ns_access(self) | source code
test_ns_access2(self) | source code
test_ns_setting(self) | source code
test_ns_tag_parse(self) | source code
test_ns_attr(self) | source code
test_ns_move(self) | source code
test_ns_decl_tostring(self) | source code
test_ns_decl_tostring_default(self) | source code
test_ns_decl_tostring_root(self) | source code
test_ns_decl_tostring_element(self) | source code
test_attribute_xmlns_move(self) | source code
test_namespaces_after_serialize(self) | source code
test_attribute_namespace_roundtrip(self) | source code
test_attribute_namespace_roundtrip_replaced(self) | source code
test_register_namespace(self) | source code
test_tostring(self) | source code
test_tostring_element(self) | source code
test_tostring_element_tail(self) | source code
test_tostring_method_html(self) | source code
test_tostring_method_text(self) | source code
test_iterparse(self) | source code
test_iterparse_incomplete(self) | source code
test_iterparse_file(self) | source code
test_iterparse_start(self) | source code
test_iterparse_start_end(self) | source code
test_iterparse_clear(self) | source code
test_iterparse_large(self) | source code
test_iterparse_attrib_ns(self) | source code
test_iterparse_getiterator(self) | source code
test_iterparse_move_elements(self) | source code
test_iterparse_cdata(self) | source code
test_parse_file(self) | source code
test_parse_file_nonexistent(self) | source code
test_parse_error_none(self) | source code
test_parse_error(self) | source code
test_parse_error_from_file(self) | source code
test_parse_file_object(self) | source code
test_parse_stringio(self) | source code
test_parse_cdata(self) | source code
test_parse_with_encoding(self) | source code
test_encoding(self) | source code
test_encoding_exact(self) | source code
test_parse_file_encoding(self) | source code
test_parse_file_object_encoding(self) | source code
test_encoding_8bit_latin1(self) | source code
test_parse_encoding_8bit_explicit(self) | source code
test_parse_encoding_8bit_override(self) | source code
_test_wrong_unicode_encoding(self) | source code
test_encoding_write_default_encoding(self) | source code
test_encoding_tostring(self) | source code
test_encoding_tostring_unknown(self) | source code
test_encoding_tostring_sub(self) | source code
test_encoding_tostring_sub_tail(self) | source code
test_encoding_tostring_default_encoding(self) | source code
test_encoding_sub_tostring_default_encoding(self) | source code
test_encoding_8bit_xml(self) | source code
test_encoding_utf8_bom(self) | source code
test_encoding_8bit_parse_stringio(self) | source code
test_deepcopy_elementtree(self) | source code
test_deepcopy(self) | source code
test_deepcopy_tail(self) | source code
test_deepcopy_subelement(self) | source code
test_deepcopy_namespaces(self) | source code
test_deepcopy_append(self) | source code
test_deepcopy_comment(self) | source code
test_shallowcopy(self) | source code
test_shallowcopy_elementtree(self) | source code
_test_element_boolean(self) | source code
test_multiple_elementrees(self) | source code
test_qname(self) | source code
test_qname_cmp(self) | source code
test_qname_attribute_getset(self) | source code
test_qname_attrib(self) | source code
test_qname_attribute_resolve(self) | source code
test_qname_attribute_resolve_new(self) | source code
test_qname_attrib_resolve(self) | source code
test_parser_version(self) | source code
test_feed_parser_bytes(self) | source code
test_feed_parser_unicode(self) | source code
test_feed_parser_error_close_empty(self) | source code
test_feed_parser_error_close_incomplete(self) | source code
test_feed_parser_error_broken(self) | source code
test_feed_parser_error_position(self) | source code
test_parser_target_property(self) | source code
test_parser_target_tag(self) | source code
test_parser_target_error_in_start(self) | source code
test_parser_target_error_in_end(self) | source code
test_parser_target_error_in_close(self) | source code
test_parser_target_error_in_start_and_close(self) | source code
test_elementtree_parser_target(self) | source code
test_parser_target_attrib(self) | source code
test_parser_target_data(self) | source code
test_parser_target_entity(self) | source code
test_parser_target_entity_unknown(self) | source code
test_treebuilder(self) | source code
test_treebuilder_target(self) | source code
_writeElement(self, element, encoding=`'``us-ascii``'`) Write out element for comparison. | source code
_writeElementFile(self, element, encoding=`'``us-ascii``'`) Write out element for comparison, using real file. | source code
assertXML(self, expected, element, encoding=`'``us-ascii``'`) Writes element out and checks whether it is expected. | source code
assertEncodingDeclaration(self, result, encoding) Checks if the result XML byte string specifies the encoding. | source code
_rootstring(self, tree) | source code
_check_element_tree(self, tree) | source code
_check_element(self, element) | source code
_check_string(self, string) | source code
_check_mapping(self, mapping) | source code
Inherited from `common_imports.HelperTestCase`: `parse`, `tearDown` Inherited from `unittest.case.TestCase`: `__call__`, `__eq__`, `__hash__`, `__init__`, `__ne__`, `__repr__`, `__str__`, `addCleanup`, `addTypeEqualityFunc`, `assertAlmostEqual`, `assertAlmostEquals`, `assertDictContainsSubset`, `assertDictEqual`, `assertEqual`, `assertEquals`, `assertFalse`, `assertGreater`, `assertGreaterEqual`, `assertIn`, `assertIs`, `assertIsInstance`, `assertIsNone`, `assertIsNot`, `assertIsNotNone`, `assertItemsEqual`, `assertLess`, `assertLessEqual`, `assertListEqual`, `assertMultiLineEqual`, `assertNotAlmostEqual`, `assertNotAlmostEquals`, `assertNotEqual`, `assertNotEquals`, `assertNotIn`, `assertNotIsInstance`, `assertNotRegexpMatches`, `assertRaises`, `assertRaisesRegexp`, `assertRegexpMatches`, `assertSequenceEqual`, `assertSetEqual`, `assertTrue`, `assertTupleEqual`, `assert_`, `countTestCases`, `debug`, `defaultTestResult`, `doCleanups`, `fail`, `failIf`, `failIfAlmostEqual`, `failIfEqual`, `failUnless`, `failUnlessAlmostEqual`, `failUnlessEqual`, `failUnlessRaises`, `id`, `run`, `setUp`, `shortDescription`, `skipTest` Inherited from `unittest.case.TestCase` (private): `_addSkip`, `_baseAssertEqual`, `_deprecate`, `_formatMessage`, `_getAssertEqualityFunc`, `_truncateMessage` Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__setattr__`, `__sizeof__`, `__subclasshook__`

Class Methods | [hide private]
Inherited from `unittest.case.TestCase`: `setUpClass`, `tearDownClass`

Class Variables | [hide private]
| etree = `None` hash(x)
| required_versions_ET = ``{``'``test_comment_text``'``:` `(`1`,` 3`)``,` `'``test_com``...``
| required_versions_cET = ``{``}``
Inherited from `unittest.case.TestCase`: `longMessage`, `maxDiff` Inherited from `unittest.case.TestCase` (private): `_classSetupFailed`, `_diffThreshold`

Properties | [hide private]
Inherited from `object`: `__class__`

Method Details | [hide private]

### assertXML(self, expected, element, encoding=`'``us-ascii``'`) | source code
Writes element out and checks whether it is expected. Does this two ways; once using BytesIO, once using a real file.

### _rootstring(self, tree) | source code
Overrides: common_imports.HelperTestCase._rootstring

Class Variable Details | [hide private]

  ### required_versions_ET Value:
      {'test_comment_text': (1, 3),
       'test_comment_whitespace': (1, 3),
       'test_extend': (1, 3),
       'test_feed_parser_error_broken': (1, 3),
       'test_feed_parser_error_close_empty': (1, 3),
       'test_feed_parser_error_close_incomplete': (1, 3),
       'test_feed_parser_error_position': (1, 3),
       'test_fromstringlist': (1, 3),
      ...