Fix Bug 436569: Get xlink:href prefix right in case of duplicate gradient

This commit is contained in:
JSCHILL1 2009-09-27 19:53:34 -05:00
parent 7e483ce92f
commit 20fe836041
3 changed files with 39 additions and 5 deletions

View file

@ -944,6 +944,12 @@ class DoNotPrettyPrintWhenNestedWhitespacePreserved(unittest.TestCase):
<text xml:space="preserve"><tspan font-style="italic">Use <tspan font-style="bold">bold</tspan> text</tspan></text>
</svg>''',
'Whitespace not preserved when nested')
class GetAttrPrefixRight(unittest.TestCase):
def runTest(self):
grad = scour.scourXmlFile('unittests/xml-namespace-attrs.svg').getElementsByTagNameNS(SVGNS, 'linearGradient')[1]
self.assertEquals( grad.getAttributeNS('http://www.w3.org/1999/xlink', 'href'), '#linearGradient841',
'Did not get xlink:href prefix right' )
# TODO; write a test for embedding rasters
# TODO: write a test for --disable-embed-rasters