[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: How to assess the correctness of a Format1 -->Format2 mapp

  • From: "Liam R. E. Quin" <liam@fromoldbooks.org>
  • To: "ml-dev@lists.xml.org" <xml-dev@lists.xml.org>
  • Date: Mon, 23 Jan 2023 17:57:15 -0500

Re:  How to assess the correctness of a Format1 -->Format2 mapp
On Mon, 2023-01-23 at 19:23 +0000, Roger L Costello wrote:
> 
> I want to know if my Format1 --> Format2 mapping is correct.
> 

what you propose is introducing two mappings, m1 and m2, to a format f3
(which happens to be in XML), so that you have
f1 -> (m0) -> f2
f1 -> (m1) -> f3
f2 -> (m2) -> f3

If f1 to f2 to f3 using m0 and m2 produces the same f3 as f1 to f3
using m2, you can guess that at least one of the following is true:

[A] m0, m1 and m2 are all flawed in the same way
[B] m0, m1 and m2 work plausibly for the subset of f1 in your input
[C] m1 is correct but m0 and m2 have flaws that happen to cancel out
[D] all are incorrect, your f3 does not represent f1

To gain confidence that scenario [B] is a correct description, you can
do a combination of

[a] detailed analysis of the transformation, to be confident it
    reflects your understanding

You can take this further with,
   [a.2] write a formal proof
   but this will only ever prove that your program satisfies the
   axioms you start with, which might or might not be correct

[b] try to write an exhaustive test suite (this is often too hard
    in practice)

[c] try lots of real-world test documents - one client recently
    wanted me to write some XSLT, and sent some 30 gigabytes of
    sample XML documents...


However, any sort of testing is likely to be a win over not testing.

liam

-- 
Liam Quin, https://www.delightfulcomputing.com/
Available for XML/Document/Information Architecture/XSLT/
XSL/XQuery/Web/Text Processing/A11Y training, work & consulting.
Barefoot Web-slave, antique illustrations:  http://www.fromoldbooks.org


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


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.