OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

tag message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Example of a potentially executable (XPath 2) Test Assertion for OASIS UBL XML Invoice


Greetings

Having fun with the markup. Here's an example I just sent to
the UBL-Dev mail list for a potentially executable xpath2-bound
test assertion for one of the calculation rules for a UBL 2.0
Invoice. Looks very usable. Could see good take-up. Now starting
to fully appreciate the TA progress. Thanks All. (Kind of feels
like a eureka moment.)

<?xml version="1.0" encoding="UTF-8"?>
<testAssertionSet xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
 xsi:noNamespaceSchemaLocation="TestAssertionMarkup-0-4/testAssertion-0-4.xsd">
   <testAssertion id="ta-example-001">
       <var name="ubl-invoice-2-0-schema">http://docs.oasis-open.org/ubl/os-UBL-2.0/xsd/common/UBL-CommonAggregateComponents-2.0.xsd</var>
       <normativeSource><refSourceItem>fn:doc($ubl-invoice-2-0-schema)/xsd:schema/xsd:complexType[64]/xsd:sequence[1]/xsd:element[1]/xsd:annotation[1]/xsd:documentation[1]/ccts:Component[1]/ccts:Definition[1]</refSourceItem></normativeSource>
       <target>/default:Invoice/cac:LegalMonetaryTotal[1]/cbc:LineExtensionAmount[1]</target>
       <prerequisite>/default:Invoice/cac:InvoiceLine[1]/cbc:LineExtensionAmount[1]</prerequisite>
       <predicate>sum(/default:Invoice/cac:InvoiceLine/cbc:LineExtensionAmount)</predicate>
       <prescriptionLevel>mandatory</prescriptionLevel>
   </testAssertion>
 <!--   <testAssertion id="ta-example-001">
     <var name="ubl-invoice-2-0-schema">http://docs.oasis-open.org/ubl/os-UBL-2.0/xsd/common/UBL-CommonAggregateComponents-2.0.xsd</var>
     <var name="ubl-invoice-2-0-instance">.</var>
     <normativeSource>
       <refSourceItem>fn:doc($ubl-invoice-2-0-schema)/xsd:schema/xsd:complexType[64]/xsd:sequence[1]/xsd:element[1]/xsd:annotation[1]/xsd:documentation[1]/ccts:Component[1]/ccts:Definition[1]</refSourceItem>
     </normativeSource>
     <target>fn:doc($ubl-invoice-2-0-instance)/default:Invoice/cac:LegalMonetaryTotal[1]/cbc:LineExtensionAmount[1]</target>
     <prerequisite>fn:doc($ubl-invoice-2-0-instance)/default:Invoice/cac:InvoiceLine[1]/cbc:LineExtensionAmount[1]</prerequisite>
     <predicate>sum(fn:doc($ubl-invoice-2-0-instance)/default:Invoice/cac:InvoiceLine/cbc:LineExtensionAmount)</predicate>
     <prescriptionLevel>preferred</prescriptionLevel>
   </testAssertion> -->
</testAssertionSet>


Best regards, Steve

Stephen D Green
Document Engineering Services Ltd


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]