;ò ðX‡>c@s¡dZddd!Zddd!Zddd!ZdkZdkZedjo$eeii eid d ƒƒnd k l Z d k l Z lZe id ƒe idƒye idƒWnnXye idƒWnnXye idƒWnnXdklZlZe iidƒ\ZZdeeefZde i fd„ƒYZedjo,dGeiƒiƒGHeddddƒndkZd„ZdS(sÄ $RCSfile: TestXSLTMethod.py,v $ Unit tests for ZopeXMLMethods product Author: Craeg Strong Modified by Philipp von Weitershausen Release: 1.0 s $Name: $iiþÿÿÿs$Date: 2003/03/30 20:51:59 $s$Revision: 1.27 $i Ns__main__is framework.py(s ZopeTestCase(s XSLTMethodsProcessorChoosersZopeXMLMethodss PageTemplatess ParsedXMLs ExternalFilesExtFile(s _folder_names_standard_permissionsishttp://%s:%d/%ssXSLTMethodTestCasecBs@tZdZd„Zd„Zd„Zd„Zd„Zd„Zd„Z d„Z d „Z d „Z d „Z d „Zd „Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Z d„Z!d „Z"d!„Z#d"„Z$RS(#su Unit tests for ZopeXMLMethods Zope Product. These tests use the ZopeTestCase enhanced testing product. cCstƒiƒdS(N(sget_transactionsbegin(sself((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pys beforeSetUp6scCs dk}|iddtƒdS(sAdd object to default fixtureNsignores(swarningssfilterwarningss UserWarning(sselfswarnings((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pys afterSetUp9s cCstƒiƒdS(N(sget_transactionscommit(sself((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pys beforeCloseHscCsdS(sClean up after myselfN((sself((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pys afterClearLscCs)|itti|iddddƒdS(s8Ensure that XSLTMethod cannot be created with a blank IDsidssxslTransformerIdN(sselfs assertRaisess Exceptions XSLTMethods addInstancesfolder(sself((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_01Ts cCs)|itti|iddddƒdS(sDEnsure that XSLTMethod cannot be created without a valid transformersids aXSLTMethodsxslTransformerIds aTransformerN(sselfs assertRaisess Exceptions XSLTMethods addInstancesfolder(sself((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_02Zs cCsr|iidƒ|iidƒ|id}ti|iddddƒ}|i|dƒ|i|i dƒdS(sAEnsure that XSLTMethod can be created with minimal correct paramss aTransformersaSourcesids aXSLTMethodsxslTransformerIds2XSLTMethod successfully created should not be NoneN( sselfsfoldersmanage_addDTMLMethodssrcs XSLTMethods addInstancesxforms failUnlesss assertEqualssid(sselfssrcsxform((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_03`s  cCs’tddƒ}|iidd|ƒtddƒ}|iidd|ƒti|iddd dƒ|i|ii i i |i i ƒd ƒd S( s+Ensure that basic transform works correctlystestfiles/simple.xslsrbs aTransformersstestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIds Hello, worldN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxsltFilesxmlFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_04ls !cCsÔtddƒ}|iidd|ƒ|iidƒ|id}|idƒ|d}|idƒ|d}tddƒ}|id d|ƒt i |d d d dƒ|i |i ii|iiƒd ƒdS(s=Ensure that we can obtain our XSLT via containment aquisitionstestfiles/simple.xslsrbs aTransformerssonestwosthreestestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIds Hello, worldN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsmanage_addFoldersonestwosthreesxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFilesthreesxsltFilestwosone((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_05zs      c Cs|iidƒ|id}|idƒ|d}|idƒ|d}tddƒ}|idd|ƒ|iidƒ|id}|id ƒ|d }|id ƒ|d }td dƒ}|id d|ƒt i|d dddƒ|i|iii|iiƒdƒdS(s9Ensure that we can obtain our XSLT via context aquisitionssomesothersplacestestfiles/simple.xslsrbs aTransformerssonestwosthreestestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIdssome/other/place/aTransformers Hello, worldN(sselfsfoldersmanage_addFolderssomesothersplacesopensxsltFilesmanage_addDTMLMethodsonestwosthreesxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST( sselfsxmlFilessomesxsltFilesonesothersplacestwosthree((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_06s*           cCsÂtddƒ}|iidd|ƒtddƒ}|iidd|ƒddg|i_d |i_d |i_t i |id d d dƒ|ii i i |iiƒ}|i|dƒdS(s>Ensure that transformation obtains scalar parameters correctlystestfiles/param.xslsrbs aTransformersstestfiles/param.xmlsaSourceswhosmessagessneezystake some claritinsids aXSLTMethodsxslTransformerIds$Hello, sneezy and take some claritinN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles XSLparametersswhosmessages XSLTMethods addInstancesaSources aXSLTMethods transformsappsREQUESTsresults assertEquals(sselfsxmlFilesxsltFilesresult((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_07¬s   cCsÔtddƒ}|iidd|ƒtddƒ}|iidd|ƒdg|i_tddƒ}|iidd|ƒti |id d d dƒd t d }|i |ii ii|iiƒ|ƒdS(sCEnsure that transformation obtains zope object parameters correctlystestfiles/propertiesfile.xslsrbs aTransformersstestfiles/param.xmlsaSources propertiesstestfiles/properties.xmlsids aXSLTMethodsxslTransformerIdsurl is s /propertiesN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles XSLparametersspropFiles XSLTMethods addInstancesbasesexpecteds assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFilespropFilesxsltFilesexpected((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_08½s !cCs8tddƒ}|iidd|ƒtddƒ}|iidd|ƒdg|i_dg|i_d |i_|ii dƒ|id}|i d ƒ|d }|i d ƒ|d }td dƒ}|idd|ƒtƒiƒti|id dddƒ}|i|iiii|iiƒdƒdS(s?Ensure that transformation resolves URLs in documents correctlystestfiles/paramfile.xslsrbs aTransformersstestfiles/param.xmlsaSources arielpartnerss propertiess'arielpartners/propfolder/foo/propertiess propfoldersfoostestfiles/properties.xmlsids aXSLTMethodsxslTransformerIds Hello, sneezyN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles URNnamespacess XSLparameterss propertiessmanage_addFolders arielpartnerss propfoldersfoospropFilesget_transactionscommits XSLTMethods addInstancesxforms assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFiles arielpartnerssxsltFilesxforms propfoldersfoospropFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_09Òs*        !cCstddƒ}|iidd|ƒtddƒ}|iidd|ƒdg|i_|iidƒ|id}|idƒ|d}|id ƒ|d }td dƒ}|id d|ƒt i |d d ddƒ|i|iii|iiƒdƒdS(s?Ensure that transformation resolves URNs in documents correctlys!testfiles/calldocumentfuncURN.xslsrbs aTransformersstestfiles/param.xmlsaSources arielpartnerss propfoldersfoostestfiles/properties.xmls propertiessids aXSLTMethodsxslTransformerIds Hello, sneezyN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles URNnamespacessmanage_addFolders arielpartnerss propfoldersfoospropFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFiles arielpartnerssxsltFiles propfoldersfoospropFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_10ôs$      cCsñtddƒ}|iidd|ƒtddƒ}|iidd|ƒdg|i_|iidƒ|id}|idƒ|d}td dƒ}|id d|ƒt i |d d d dƒ|i |i ii|iiƒdƒdS(sBEnsure that transformation resolves URNs in transformers correctlystestfiles/includeURN.xslsrbs aTransformersstestfiles/simple.xmlsaSources arielpartnerssxformsstestfiles/simple.xslssimplesids aXSLTMethodsxslTransformerIds Hello, worldN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles URNnamespacessmanage_addFolders arielpartnerssxformss XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFiles arielpartnerssxsltFilesxforms((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_11s     cCs#tddƒ}|iidd|ƒtddƒ}|iidd|ƒdg|i_|iidƒ|id}|idƒ|d}t i |d d d dƒy|i i i|iiƒWnYtj oM}|it|ƒid ƒd jƒ|it|ƒidƒd jƒnXdS(sNVerify error report if stylesheet URN resolver cannot find included stylesheetstestfiles/includeURN.xslsrbs aTransformersstestfiles/simple.xmlsaSources arielpartnerssxformssids aXSLTMethodsxslTransformerIdsurniÿÿÿÿsarielpartners:xforms/simpleN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles URNnamespacessmanage_addFolders arielpartnerssxformss XSLTMethods addInstancesaSources aXSLTMethods testTransformsappsREQUESTs ExceptionsesfailIfsstrsfind(sselfsxmlFileses arielpartnerssxsltFilesxforms((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_12&s"    "cCstddƒ}|iidd|ƒtddƒ}|iidd|ƒdg|i_|iidƒ|id}|idƒ|d}t i |id d d dƒy |ii i i|iiƒWn7tj o+}|it|ƒid ƒd jƒnXdS(sJVerify error report if document URN resolver cannot find included documents!testfiles/calldocumentfuncURN.xslsrbs aTransformersstestfiles/param.xmlsaSources arielpartnerss propfoldersids aXSLTMethodsxslTransformerIdsdocumentiÿÿÿÿN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles URNnamespacessmanage_addFolders arielpartnerss propfolders XSLTMethods addInstancesaSources aXSLTMethods testTransformsappsREQUESTs ExceptionsesfailIfsstrsfind(sselfsxmlFileses arielpartnerssxsltFiles propfolder((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_13As      cCs%tddƒ}|iidd|ƒtddƒ}|iidd|ƒdg|i_dg|i_d |i_|ii dƒ|id}|i d ƒ|d }|i d ƒ|d }|i d ƒ|d }|i d ƒti|iddddƒ|it|iii|iiƒdS(sBVerify error report if document URN resolver gets badly formed URNstestfiles/paramfile.xslsrbs aTransformersstestfiles/param.xmlsaSources arielpartnerss propertiess)urn:arielpartners:propfolder/i/dont/exists propfoldersisdontsexistsids aXSLTMethodsxslTransformerIdN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles URNnamespacess XSLparameterss propertiessmanage_addFolders arielpartnerss propfoldersisdonts XSLTMethods addInstances assertRaisess ExceptionsaSources aXSLTMethods testTransformsappsREQUEST(sselfsxmlFiles arielpartnerssisxsltFiles propfoldersdont((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_14\s,            cCs°tddƒ}|iidd|ƒtddƒ}|iidd|ƒd|i_ti|idd d dƒ|ii i }|||i i ƒ}|i|iƒd ƒd S( s1Ensure that transformation can produce valid DTMLstestfiles/dtmltest.xslsrbs aTransformersstestfiles/param.xmlsaSourcessneezysids aXSLTMethodsxslTransformerIds Hello, sneezyN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFileswhos XSLTMethods addInstancesaSources aXSLTMethodsxformsappsREQUESTsresults assertEqualssstrip(sselfsxmlFilesxsltFilesresultsxform((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_15ys  cCs¾tddƒ}|iidd|ƒtddƒ}|iidd|ƒti|iddd dƒtd dƒ}|ii d d|ƒ|id }||ƒ}|i |i ƒd ƒd S(s2Ensure that transformation resolves DTML correctlystestfiles/simple.xslsrbs aTransformersstestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIdstestfiles/dtmltest.dtmlsdtmltests
Hello, world
N(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles XSLTMethods addInstancesdtmlFilesmanage_addDTMLDocumentsdtmltestsresults assertEqualssstrip(sselfsxmlFilesdtmlFilesxsltFilesdtmltestsresult((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_16Šs   cCs½tddƒ}|iidd|ƒtddƒ}|iididd|ƒd|i_t i |id d d dƒ|ii i }|||iiƒ}|i|id ƒd jƒdS(s0Ensure that transformation can produce valid ZPTstestfiles/templatetest.xslsrbs aTransformersstestfiles/param.xmls PageTemplatessaSourcessneezysids aXSLTMethodsxslTransformerIds Hello, sneezyiÿÿÿÿN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFilesmanage_addProductsmanage_addPageTemplateswhos XSLTMethods addInstancesaSources aXSLTMethodsxformsappsREQUESTsresultsfailIfsfind(sselfsxmlFilesxsltFilesresultsxform((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_17›s  cCsàtddƒ}|iidd|ƒtddƒ}|iidd|ƒd|i_ti|idd d dd d ƒtd dƒ}|ii di dd|ƒ|id}|||i iƒ}|i|iƒdƒdS(s<Ensure that transformation resolves page templates correctlystestfiles/simple.xslsrbs aTransformersstestfiles/simple.xmlsaSourcessneezysids aXSLTMethodsxslTransformerIds behave_likes Page Templatestestfiles/zpttest.zpts PageTemplatesszpttests Hello, worldN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFileswhos XSLTMethods addInstanceszptFilesmanage_addProductsmanage_addPageTemplateszpttestsappsREQUESTsresults assertEqualssstrip(sselfsxmlFileszptFilesxsltFilesresultszpttest((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_18²s   cCsà|iidƒ|id}tddƒ}|idd|ƒtddƒ}|iidd|ƒtddƒ}|iid d|ƒtƒi ƒt i |id d d d ƒ}|i |iiii|iiƒdƒdS(s;Ensure that transformation resolves relative URLs correctlyssubstestfiles/include.xslsrbs aTransformersstestfiles/simple.xslssimplestestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIdssub/aTransformers Hello, worldN(sselfsfoldersmanage_addFolderssubsopensxsltFilesmanage_addDTMLMethodsxmlFilesget_transactionscommits XSLTMethods addInstancesxforms assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFilessubsxsltFilesxform((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_19Ès   !c Cstddƒ}|iidd|ƒtddƒ}|iidd|ƒdg|i_|iidƒ|id}|idƒ|d}|id ƒ|d }td dƒ}|id d|ƒt i |d d ddƒ}|iii|iiƒ}|i|iƒdƒdS(sTest URN resolution in XSLTstestfiles/calldocURN2.xslsrbs aTransformersstestfiles/include.xmlsaSources arielpartnerss propfoldersfoostestfiles/properties.xmls propertiessids aXSLTMethodsxslTransformerIds Hello, sneezyN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles URNnamespacessmanage_addFolders arielpartnerss propfoldersfoospropFiles XSLTMethods addInstancesxformsaSources aXSLTMethods transformsappsREQUESTsresults assertEqualssstrip( sselfsxmlFiles arielpartnerssxsltFilesxforms propfoldersresultsfoospropFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_20âs$      cCs tddƒ}|iididd|ƒtddƒ}|iididd|ƒti|idd d dƒ|i |ii i i |i iƒd ƒd S( s:Make sure page templates can be used for both XML and XSLTstestfiles/simple.xslsrbs PageTemplatess aTransformersstestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIds Hello, worldN(sopensxsltFilesselfsfoldersmanage_addProductsmanage_addPageTemplatesxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxsltFilesxmlFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_21üs   !cCsŒtddƒ}|iid|ƒtddƒ}|iid|ƒti|iddddƒ|i|ii i i |i i ƒd ƒd S( s'Try using File objects for XML and XSLTstestfiles/simple.xslsrbs aTransformerstestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIds Hello, worldN(sopensxsltFilesselfsfoldersmanage_addFilesxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxsltFilesxmlFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_22 s !cCsÐydkl}WndGHdSnXtddƒ}|iididd|iƒƒtd dƒ}|iidid d|iƒƒt i |id d d dƒ|i |ii ii|iiƒdƒdS(s,Try using ParsedXML objects for XML and XSLT(s ParsedXMLs-ParsedXML product not found, skipping test...istestfiles/simple.xslsrbs ParsedXMLs aTransformersstestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIds Hello, worldN(sProducts.ParsedXML.ParsedXMLs ParsedXMLsopensxsltFilesselfsfoldersmanage_addProductsmanage_addParsedXMLsreadsxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFiles ParsedXMLsxsltFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_23s  !cCs’tddƒ}|iidd|ƒtddƒ}|iidd|ƒti|iddd dƒ|i|ii i i |i i ƒd ƒd S( s0Try using DTML Document objects for XML and XSLTstestfiles/simple.xslsrbs aTransformersstestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIds Hello, worldN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxsltFilesxmlFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_242s !cCs¾ydkl}WndGHdSnXd}|iididddd|ƒd }|iidid ddd|ƒti |id d d dƒ|i |ii i i |iiƒdƒdS(s/Try using ExternalFile objects for XML and XSLT(s ExternalFiles0ExternalFile product not found, skipping test...istestfiles/simple.xsls ExternalFiles aTransformersstarget_filepathstestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIds Hello, worldN(s"Products.ExternalFile.ExternalFiles ExternalFilesxsltFilesselfsfoldersmanage_addProducts manage_addsxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxsltFilesxmlFiles ExternalFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_25As    !cCsÄydkl}WndGHdSnXtddƒ}|iididd|ƒtd dƒ}|iidid d|ƒt i |id d d dƒ|i |ii i i|iiƒdƒdS(s*Try using ExtFile objects for XML and XSLT(sExtFiles+ExtFile product not found, skipping test...istestfiles/simple.xslsrbsExtFiles aTransformersfilestestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIds Hello, worldN(sProducts.ExtFile.ExtFilesExtFilesopensxsltFilesselfsfoldersmanage_addProductsmanage_addExtFilesxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFilesExtFilesxsltFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_26Xs !cCsGtddƒ}|iidd|ƒtddƒ}|iidd|ƒtddƒ}|iidd|ƒtd dƒ}|iid d|ƒti|id d d dƒti|id dd dƒti|id dd dƒd}|ii di dd|ƒ|id}|||i i ƒ}|i|iƒdƒdS(sTest XSLT Pipelinesstestfiles/pipeline1.xslsrbsxslt1sstestfiles/pipeline2.xslsxslt2stestfiles/pipeline3.xslsxslt3stestfiles/simple.xmlsaSourcesidstran1sxslTransformerIdstran2stran3s@
Oh, crap
s PageTemplatessaZPTs Hello, worldN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFiles XSLTMethods addInstancestextsmanage_addProductsmanage_addPageTemplatesaZPTsappsREQUESTsresults assertEqualssstrip(sselfsaZPTsxmlFilestextsxsltFilesresult((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_27ms*     cCsÔtddƒ}|iidd|ƒ|iidƒ|id}|idƒ|d}|idƒ|d}tddƒ}|id d|ƒt i |d d d dƒ|i |i ii|iiƒd ƒdS(sTEnsure that we can obtain our XSLT via more than one level of containment aquisitionstestfiles/simple.xslsrbs aTransformerssonestwosthreestestfiles/simple.xmlsaSourcesids aXSLTMethodsxslTransformerIds Hello, worldN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsmanage_addFoldersonestwosthreesxmlFiles XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFilesthreesxsltFilestwosone((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_28s      cCsãtddƒ}|iidd|ƒtddƒ}|iidd|ƒ|iidƒ|id}|idƒ|d}|id ƒ|d }t i |d d d dƒ|i |ii iii ii|iiƒd ƒdS(s>Ensure that we can call an XSLTMethod using context aquisitionstestfiles/simple.xslsrbs aTransformersstestfiles/simple.xmlsaSourcesonestwosthreesids aXSLTMethodsxslTransformerIds Hello, worldN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFilesmanage_addFoldersonestwosthrees XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfsxmlFilesxsltFilesonestwosthree((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_29¢s      *cCstddƒ}|iidd|ƒtddƒ}|iidd|ƒtddƒ}|iidd|ƒd|i_|iid ƒ|id }td dƒ}|id d|ƒt ƒi ƒt i|id d ddƒ|i|iiii|iiƒdƒdS(sQEnsure that transformation resolves URNs in documents correctly using XML catalogs!testfiles/calldocumentfuncURN.xslsrbs aTransformersstestfiles/param.xmlsaSourcestestfiles/catalog.xmlsaCatalogsbarstestfiles/properties.xmls propertiessids aXSLTMethodsxslTransformerIds Hello, sneezyN(sopensxsltFilesselfsfoldersmanage_addDTMLMethodsxmlFilescatFiles XMLcatalogsmanage_addFoldersbarspropFilesget_transactionscommits XSLTMethods addInstances assertEqualssaSources aXSLTMethods transformsappsREQUEST(sselfscatFilesxmlFilesbarspropFilesxsltFile((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pystest_30·s"    !(%s__name__s __module__s__doc__s beforeSetUps afterSetUps beforeCloses afterClearstest_01stest_02stest_03stest_04stest_05stest_06stest_07stest_08stest_09stest_10stest_11stest_12stest_13stest_14stest_15stest_16stest_17stest_18stest_19stest_20stest_21stest_22stest_23stest_24stest_25stest_26stest_27stest_28stest_29stest_30(((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pysXSLTMethodTestCase,sF             "                   sUsing processor:s descriptionsis verbosityicCs*tiƒ}|ititƒƒ|SdS(N(sunittests TestSuitessuitesaddTests makeSuitesXSLTMethodTestCase(ssuite((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pys test_suiteès (s__doc__s __cvstag__s__date__s __version__sosssyss__name__sexecfilespathsjoinsTestings ZopeTestCasesProducts.ZopeXMLMethodss XSLTMethodsProcessorChoosersinstallProductsTesting.ZopeTestCases _folder_names_standard_permissionssutilss startZServershostsportsbasesXSLTMethodTestCasesdefaultProcessors frameworksunittests test_suite(s__date__s _folder_names ZopeTestCasesunittests_standard_permissionss XSLTMethodsProcessorChoosers __cvstag__shostsbasessyss test_suites __version__sossportsXSLTMethodTestCase((sR/mnt/gmirror/ports/www/zope-xmlmethods/work/ZopeXMLMethods/tests/TestXSLTMethod.pys? sB    $   ÿÿ±