To discuss as part of action 066.
a) IBM has shared the IBM DFDL error
messages. They use an IBM-defined error number but eventually this should
be replaced/augmented by an OGF DFDL WG defined code. See Tim's email below,
which describes how the XSDL spec does this.
b) It was noted that the IBM and Daffodil
tdml runners should be converged. First step towards this is for IBM to
get permission to download the Daffodil tests. Steve has kicked this off
today.
Perhaps action 066 should be closed
and more specific actions spawned for the above?
Regards
Steve Hanson
Architect, Data Format Description Language (DFDL)
Co-Chair, OGF
DFDL Working Group
IBM SWG, Hursley, UK
smh@uk.ibm.com
tel:+44-1962-815848
----- Forwarded by Steve
Hanson/UK/IBM on 18/06/2012 09:38 -----
From:
Tim Kimber/UK/IBM
To:
Mike Beckerle <mbeckerle.dfdl@gmail.com>
Cc:
Steve Hanson/UK/IBM@IBMGB
Date:
13/06/2012 21:42
Subject:
Re: TDML question
Hi Mike,
Fair question. IBM requires all diagnostic
messages from its software products to be identified by a unique error
code. In the IBM test driver program, it is this code that we check for.
The XML Schema specification actually
assigns unique strings to the various types of error that can occur ( e.g.
cvc-* ). If the DFDL specification did the same then the TDML format
would be able to specify that the content of the <errors> tag is
a list of defined error codes.
For DFDL v1.0, I think implementers
are free to use it in a way that fits their own requirements.
regards,
Tim Kimber, Common Transformation Team,
Hursley, UK
Internet: kimbert@uk.ibm.com
Tel. 01962-816742
Internal tel. 246742
From:
Mike Beckerle <mbeckerle.dfdl@gmail.com>
To:
Steve Hanson/UK/IBM@IBMGB,
Tim Kimber/UK/IBM@IBMGB
Date:
13/06/2012 20:45
Subject:
TDML question
I'm enhancing the daffodil TDML runner. I want to keep it compatible with
the IBM one so that we can use TDML files as an interchange medium for
discussing bugs/semantics/etc.
I added the error feature where one can put expected errors into the TDML
file.
I have a question about the <error>...</error> element. Which
is this: How is the string contents of these error elements used?
I tentatively just have it search the error messages created by the parse
for these error strings. If any actual error message contains the error
string, then that error "passes".
Here's my example, which is parsing a 2 character integer, which will fail
because the text is AA, and this is base 10.
<ts:testSuite xmlns:ts={ tdml } suiteName="theSuiteName">
<ts:parserTestCase ID="some identifier" name="firstUnitTest"
root="data">
<ts:document>AA</ts:document>
<ts:errors>
<ts:error>convert</ts:error> <!-- can have several substrings
of message -->
<ts:error>xs:int</ts:error>
<!-- all are checked against the message -->
</ts:errors>
</ts:parserTestCase>
</ts:testSuite>
So my test passes so long as the words "convert" and "xs:int"
are found in the error message that is generated.
Is this consistent with your TDML file usage?
...mikeb
--
Mike Beckerle | OGF DFDL WG Co-Chair
Tel: 781-330-0412
Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number
741598.
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6
3AU