From 882f1aff778b56bbc15222baa0555616f8e102ac Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Fri, 19 Jan 2018 19:36:56 +0000 Subject: Replace __getitem__ with find_target_by_relationship_id on Relationships --- tests/docx/relationships_xml_tests.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'tests') diff --git a/tests/docx/relationships_xml_tests.py b/tests/docx/relationships_xml_tests.py index f2280d9..c3d0af0 100644 --- a/tests/docx/relationships_xml_tests.py +++ b/tests/docx/relationships_xml_tests.py @@ -1,8 +1,7 @@ from nose.tools import istest, assert_equal from mammoth.docx.xmlparser import element as xml_element -from mammoth.docx.relationships_xml import \ - read_relationships_xml_element, Relationship +from mammoth.docx.relationships_xml import read_relationships_xml_element @istest @@ -16,6 +15,6 @@ def target_is_read_from_relationship_element(): ]) relationships = read_relationships_xml_element(element) assert_equal( - Relationship(target="http://example.com"), - relationships["rId8"], + "http://example.com", + relationships.find_target_by_relationship_id("rId8"), ) -- cgit v1.2.3