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

 


Help: OASIS Mailing Lists Help | MarkMail Help

ubl-dev message

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


Subject: Re: Test Assertions for UBL Calculation Model? Re: Re: [ubl-dev] Basic Invoice Exploration


At 2009-06-23 21:36 +0100, Stephen Green wrote:
>I added to wiki what could be a possible start on which entities
>need the calculation assertions

I have taken your examples and I've proposed a pro-forma use of the 
wiki to express the needed test assertions:

   http://wiki.oasis-open.org/ubl/Example_Calculation_Models#proforma

... and fleshed it out with your first examples here:

   http://wiki.oasis-open.org/ubl/Example_Calculation_Models/Invoice_Tax_Total

>I realise it's a little different to your proposed way forward Ken.
>I'm more inclined to think the way to go is to set up a project
>for assertions about the calculation model which feeds directly
>into the UBL TC and its process for authoritative approval
>rather than start with a more distant model like the OIO-UBL one
>which might be seen as a customisation model rather than
>official UBL TC one.

One ramification of using an assertion (with true/false results) is 
that the expression doesn't really look like a calculation, though of 
course it incorporates the calculation.

Whereas I originally had:

   sum( ../cac:TaxSubtotal/cbc:TaxAmount )

... to make that into an assertion it has to read:

   . eq sum( ../cac:TaxSubtotal/cbc:TaxAmount )

Now that isn't a big change, and I can live with it, but it changes 
the "feel" of the document.

I can live with it because as a programmer, if I see the test 
condition I can infer what I have to do to make the test evaluate to true.

And, it means that if someone has a TA engine they could run their 
generated instances through the TA engine and get a report that 
they've met the conditions.

When it comes time to write the HISC document, we'll have to explain 
the perspective of the calculation model documentation as one of 
"confirming the calculation model has been followed" rather than "the 
steps of calculation".

Jaymuz (and others) ... do you feel that test assertions can 
effectively document what you need to implement in your systems?

Stephen ... can you improve on the pro-forma and examples based on 
your previous work with test assertions?  On the cover page I've 
assumed the expression language is XPath 2.0 and I've left the 
identification of the assertions to the step when we assemble them 
into our document.

. . . . . . . . . . . Ken

--
Crane Softwrights Ltd.          http://www.CraneSoftwrights.com/u/
Training tools: Comprehensive interactive XSLT/XPath 1.0/2.0 video
Video lesson:    http://www.youtube.com/watch?v=PrNjJCh7Ppg&fmt=18
Video overview:  http://www.youtube.com/watch?v=VTiodiij6gE&fmt=18
G. Ken Holman                 mailto:gkholman@CraneSoftwrights.com
Male Cancer Awareness Nov'07  http://www.CraneSoftwrights.com/u/bc
Legal business disclaimers:  http://www.CraneSoftwrights.com/legal



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