Re: Seek for advice with Xerces xml-schema-1.1-tests

Svante Schubert <[email protected]> Thu, 12 Sep 2024 08:24:17 +0200
Newsgroups gmane.text.xml.xerces-j.user
Message-ID <CAHNbw8kT1JDNgzeSNhYDQkrkOmE3UyOVeyuPB+y0JMNvReZ+bg@mail.gmail.com>
--0000000000009e9dcf0621e6284d
Content-Type: text/plain; charset="UTF-8"

Dear Xerces user group,

Let me add the specification reference to the invalidness of the test file
<https://github.com/apache/xerces-j/blob/xml-schema-1.1-tests/data/version-control/test37.xsd#L5>
: https://www.w3.org/TR/xmlschema11-1/#concepts-nameSymbolSpaces
*"But it is not possible for ... two distinct top-level element
declarations, to share the name my:abc"*

If the build were in Maven and nightly tests were run by GitHub, I would
not ask this question. Perhaps it is worth considering a switch from Ant to
Maven?
In general, invalid test files should be explicitly marked as such like
within a subfolder 'invalid'.
Would be helpful to download groups of test files from Maven, like versions
of deliverables as well (but this might be a topic for Maven's user's
list)...

Still, I believe I am doing an oversight...

Best regards,
Svante

PS: Used my Apache email now and am uncertain if I should have started on
the dev list right away instead of users - I would join these lists for
software in general... (as you want to users become developers..)

On Wed, 11 Sept 2024 at 15:25, Svante Schubert <[email protected]>
wrote:

> Dear experts,
>
> I am in need of some advice using the new Xerces xml-schema-1.1-tests
> <https://github.com/apache/xerces-j/tree/xml-schema-1.1-tests>.
>
> The test suite of org.apache.xerces.tests.AllXercesXSD11Tests
> <https://github.com/apache/xerces-j/blob/xml-schema-1.1-tests/src/org/apache/xerces/tests/AllXercesXSD11Tests.java#L31>
> fails for me using my Xerces Jar from a build of Xerces 1.1 GitHub branch
> <https://github.com/apache/xerces-j/tree/xml-schema-1.1-dev> and likely I
> am missing something obvious.
> The error given is "*sch-props-correct.2: An XSD schema cannot contain
> two global components with the same name.*" and *the test file does have
> two global element name declarations with the same name*
> <https://github.com/apache/xerces-j/blob/xml-schema-1.1-tests/data/version-control/test37.xsd#L5>,
> still the test is not meant to fail.
>
> What did I miss?
>
> My steps to do my smoke testing:
>
>    1. As I am not able to easily build & debug with my IDEs (like with
>    Maven) using the existing ANT scripts, I generated an easy build & debug
>    environment for my set of IDEs (Apache Netbeans & Intellij IDEA) represented
>    by a single commit of noise
>    <https://github.com/svanteschubert/xerces-j/commit/7e32264aabbb366360d6a354d2589e1e154fb58f>
>    .
>    2. Instead of setting an environment variable, I hard coded the path
>    to my tests
>    <https://github.com/svanteschubert/xerces-j/commit/2c50b9c6dc88c5394af95d12f6cad9cced822e9e>
>    .
>    3. Executed in Netbeans test suite
>    org.apache.xerces.tests.AllXercesXSD11Tests
>    <https://github.com/apache/xerces-j/blob/xml-schema-1.1-tests/src/org/apache/xerces/tests/AllXercesXSD11Tests.java#L31> and
>    getting aside of the above so many errors that I must have done something
>    basic wrong.
>
> Thanks for any help!
> Svante
>

--0000000000009e9dcf0621e6284d
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div>Dear Xerces user group,</div><div><br></div>Let me ad=
d the specification reference to the <a href=3D"https://github.com/apache/x=
erces-j/blob/xml-schema-1.1-tests/data/version-control/test37.xsd#L5">inval=
idness of the test file</a>:=C2=A0<a href=3D"https://www.w3.org/TR/xmlschem=
a11-1/#concepts-nameSymbolSpaces">https://www.w3.org/TR/xmlschema11-1/#conc=
epts-nameSymbolSpaces</a><div><b><i>&quot;But it is not possible for ... tw=
o distinct top-level element declarations, to share the name=C2=A0<span sty=
le=3D"color:rgb(0,0,0);font-family:monospace;font-size:13px">my:abc</span>&=
quot;</i></b></div><div><br></div><div>If the build were in Maven and night=
ly tests were run by GitHub, I would not ask this question. Perhaps it is w=
orth considering a switch from Ant to Maven?</div><div>In general, invalid =
test files should be explicitly marked as such like within a subfolder &#39=
;invalid&#39;.=C2=A0</div><div>Would be helpful to download groups of test =
files from Maven, like versions of deliverables as well (but this might be =
a topic for Maven&#39;s user&#39;s list)...</div><div><br></div><div>Still,=
 I believe I am doing an oversight...</div><div><br></div><div>Best regards=
,</div><div>Svante</div><div><br></div><div>PS: Used my Apache email now an=
d am uncertain if I should have started on the dev list right away instead =
of users - I would join these lists for software in general... (as you want=
 to users become developers..)</div></div><br><div class=3D"gmail_quote"><d=
iv dir=3D"ltr" class=3D"gmail_attr">On Wed, 11 Sept 2024 at 15:25, Svante S=
chubert &lt;<a href=3D"mailto:[email protected]">svante.schubert@gm=
ail.com</a>&gt; wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"=
margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-lef=
t:1ex"><div dir=3D"ltr">Dear experts,<div><br></div><div>I am in need of so=
me advice using the <a href=3D"https://github.com/apache/xerces-j/tree/xml-=
schema-1.1-tests" target=3D"_blank">new Xerces=C2=A0xml-schema-1.1-tests</a=
>.</div><div><br></div><div>The <a href=3D"https://github.com/apache/xerces=
-j/blob/xml-schema-1.1-tests/src/org/apache/xerces/tests/AllXercesXSD11Test=
s.java#L31" target=3D"_blank">test suite of org.apache.xerces.tests.AllXerc=
esXSD11Tests</a> fails for me using my Xerces Jar from a build of=C2=A0<a h=
ref=3D"https://github.com/apache/xerces-j/tree/xml-schema-1.1-dev" target=
=3D"_blank">Xerces 1.1 GitHub branch</a> and likely I am=C2=A0missing somet=
hing obvious.</div><div>The error given is &quot;<b><i>sch-props-correct.2:=
 An XSD schema cannot contain two global components with the same name.</i>=
</b>&quot; and <a href=3D"https://github.com/apache/xerces-j/blob/xml-schem=
a-1.1-tests/data/version-control/test37.xsd#L5" target=3D"_blank"><i><b>the=
 test file does have two global element name declarations=C2=A0with the sam=
e name</b></i></a>, still the test is not meant to fail.=C2=A0</div><div><b=
r></div><div>What did I miss?</div><div><br></div><div>My steps to do my sm=
oke testing:</div><div><ol><li>As I am not able to easily build &amp; debug=
 with my IDEs (like with Maven) using the existing ANT scripts, I generated=
 an easy build &amp; debug environment for my set of IDEs (Apache Netbeans =
&amp; Intellij IDEA) represented<a href=3D"https://github.com/svanteschuber=
t/xerces-j/commit/7e32264aabbb366360d6a354d2589e1e154fb58f" target=3D"_blan=
k"> by a single commit of noise</a>.</li><li>Instead of setting an environm=
ent=C2=A0variable, <a href=3D"https://github.com/svanteschubert/xerces-j/co=
mmit/2c50b9c6dc88c5394af95d12f6cad9cced822e9e" target=3D"_blank">I hard cod=
ed the path to my tests</a>.<br></li><li>Executed in Netbeans=C2=A0<a href=
=3D"https://github.com/apache/xerces-j/blob/xml-schema-1.1-tests/src/org/ap=
ache/xerces/tests/AllXercesXSD11Tests.java#L31" target=3D"_blank">test suit=
e org.apache.xerces.tests.AllXercesXSD11Tests</a>=C2=A0and getting aside of=
 the above so many errors that I must have done something basic wrong.</li>=
</ol></div><div>Thanks for any help!</div><div>Svante</div></div>
</blockquote></div>

--0000000000009e9dcf0621e6284d--