Dom Test Suites basic questions

Elise Nguyen <[email protected]> Fri, 06 May 2005 18:43:53 -0700
Newsgroups gmane.comp.web.dom.test-suites.general
Message-ID <[email protected]>
This is a multi-part message in MIME format.

--Boundary_(ID_EiWX4o3D2dOyDc6BVFA2HQ)
Content-type: text/plain; charset=us-ascii
Content-transfer-encoding: 7BIT

Hello,
 
I am a newbie with using Dom Test Suites and hope I could ask someone some
questions. Thank you in advance for your assistance
 
1)   QUESTION 1 :Would like to ask where to get the most updated test
suites. Could I use the zip files at http://www.w3.org/DOM/Test/ , are they
of latest ? 
      My company is trying to implement Dom2-Core  and Dom-3-Events and I am
in need to get those w3c test suites series to test. 
      I can only find Dom2-Core, Dom3-Core but NOT Dom3-Events at link
above.  
 
      1.1   since couldn't find it there, I try login to CVS repository and
download following instructions here:
http://www.w3.org/DOM/Test/Documents/DOMTSBuild.html 
 
      1.2  Then try to run "ant dom2-core-jar"  and got this error at this
step in build.xml (the link in blue below is no longer available !!!)    
             QUESTION : Please tell me what is the url name change to ?


<target name="dom2-schema" depends="dom2-interfaces">
        <style in="${build.dir}/dom2-interfaces.xml"
               out="${build.dir}/dom2.xsd"
               style="${transforms.dir}/dom-to-xsd.xsl">
                <param name="schema-namespace"
 
expression="http://www.w3.org/2001/DOM-Test-Suite/Level-2"/
<http://www.w3.org/2001/DOM-Test-Suite/Level-2> >
 
        </style>
 

2)    In the Dom2-Core zip file I downloaded, I saw in
org.w3c.domts.JunitRunner class, there is this code section below. Sorry if
this may be a trivial QUESTION 2 : In real life implementation, why would
one wants to access 2 configurations. Why are there need to get 2
configuration settings ?
 

    DOMTestDocumentBuilderFactory factory1 =
    new JAXPDOMTestDocumentBuilderFactory(null,
    JAXPDOMTestDocumentBuilderFactory.getConfiguration1());


    printPrologue();
    printImplementation(factory1);
    printAttributes(factory1);
    int result1 = runTest(testConstructor, factory1);
 
    DOMTestDocumentBuilderFactory factory2 =
    new JAXPDOMTestDocumentBuilderFactory(null,
   JAXPDOMTestDocumentBuilderFactory.getConfiguration2());

    printAttributes(factory2);
    int result2 = runTest(testConstructor, factory2);
    if(result1 != 0) {
        System.exit(result1);
    }
    System.exit(result2);


3)  QUESTION 3 :  Is Level 3 -Events test suites available yet ?  In trying
to find Dom-L3-Events, I downloaded the "Dom3-core-tests-20040405" zip file
at http://www.w3.org/DOM/Test/. 
    
     Unzip and in there I found Level-2 Events but NOT Level-3-Events   ?
(C:\ Dom3-core-tests-20040405 \ org \ w3c \ domts \ level2 \ events)
 
4)  QUESTION 4 : There are references to "alltests"  called in many test
suites (Test suites : TestDefaultParser , TestBatik.... etc as below...) ,
yet  I COULD NOT find their respective
level2.events.alltests."alltests.java".  In the zip file mentioned above, I
saw class "alltests.java" exist ONLY in package "org.w3c.domts.level3.core".
Is this class  mis-placed ? May be this is related to java classloader but
please excuse me if this is trivial question and help me understand.

public class TestDefaultParser extends TestSuite {
 
  public static TestSuite suite() throws Exception
  {
    Class testClass =
ClassLoader.getSystemClassLoader().loadClass("org.w3c.domts.level2.events.al
ltests");
    Constructor testConstructor = testClass.getConstructor(new Class[] {
DOMTestDocumentBuilderFactory.class });

 
Best regards
-Elise Nguyen

--Boundary_(ID_EiWX4o3D2dOyDc6BVFA2HQ)
Content-type: text/html; charset=us-ascii
Content-transfer-encoding: 7BIT

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2900.2627" name=GENERATOR></HEAD>
<BODY>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005>Hello,</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN class=232385200-07052005>I am a newbie with 
using Dom Test Suites and hope I could ask someone some questions.&nbsp;<FONT 
face=Arial size=2><SPAN class=232385200-07052005>Thank you in advance for your 
assistance</SPAN></FONT></SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN class=232385200-07052005>1)&nbsp;&nbsp; 
<U>QUESTION 1 :</U><U>Would like to ask where to get the most updated test 
suites.</U> Could I use the zip files at <A 
href="http://www.w3.org/DOM/Test/">http://www.w3.org/DOM/Test/</A> , 
are&nbsp;they of latest ? </SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; My company is trying to 
implement Dom2-Core&nbsp; and Dom-3-Events and I am in need to get those w3c 
test suites series to test. </SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; I can only find 
Dom2-Core, Dom3-Core but NOT Dom3-Events at link above.&nbsp; 
</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1.1&nbsp;&nbsp; since 
couldn't find it there,&nbsp;I try login to CVS repository and download 
following instructions here: <A 
href="http://www.w3.org/DOM/Test/Documents/DOMTSBuild.html">http://www.w3.org/DOM/Test/Documents/DOMTSBuild.html</A> 
</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1.2&nbsp; Then try to 
run "ant dom2-core-jar"&nbsp; and got this error at this step in build.xml (the 
link in blue below is no longer available !!!)&nbsp;</SPAN></FONT><FONT 
face=Arial size=2><SPAN 
class=232385200-07052005>&nbsp;&nbsp;&nbsp;</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<U>QUESTION </U>:<U> Please tell me what is the&nbsp;url name change to ?</U> 
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN></FONT></DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
    <DIV><FONT face=Arial size=2><SPAN class=232385200-07052005>&lt;target 
    name="dom2-schema" depends="dom2-interfaces"&gt;</SPAN></FONT></DIV>
    <DIV><FONT face=Arial size=2><SPAN 
    class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
    &lt;style in="${build.dir}/dom2-interfaces.xml"</SPAN></FONT></DIV>
    <DIV><FONT face=Arial size=2><SPAN 
    class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
    out="${build.dir}/dom2.xsd"</SPAN></FONT></DIV>
    <DIV><FONT face=Arial size=2><SPAN 
    class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
    style="${transforms.dir}/dom-to-xsd.xsl"&gt;</SPAN></FONT></DIV>
    <DIV><FONT face=Arial size=2><SPAN 
    class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
    &lt;param name="schema-namespace"</SPAN></FONT></DIV>
    <DIV><FONT face=Arial size=2><SPAN 
    class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
    expression="<A 
    href='http://www.w3.org/2001/DOM-Test-Suite/Level-2"/'>http://www.w3.org/2001/DOM-Test-Suite/Level-2"/</A>&gt;</SPAN></FONT></DIV>
    <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
    <DIV><FONT face=Arial size=2><SPAN 
    class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
    &lt;/style&gt;</SPAN></FONT></DIV>
    <DIV><FONT face=Arial size=2><SPAN 
    class=232385200-07052005></SPAN></FONT>&nbsp;</DIV></BLOCKQUOTE></BLOCKQUOTE>
<DIV dir=ltr><FONT face=Arial size=2><SPAN 
class=232385200-07052005>2)&nbsp;&nbsp;&nbsp; In the Dom2-Core zip file I 
downloaded, I saw in org.w3c.domts.JunitRunner class, there is&nbsp;this code 
section below. Sorry if this may be a trivial&nbsp;<U>QUESTION&nbsp;2 : In real 
life implementation, why would one wants to access 2 configurations. Why are 
there need to get 2 configuration settings ?</U></SPAN></FONT></DIV>
<DIV dir=ltr><FONT face=Arial size=2><SPAN 
class=232385200-07052005></SPAN></FONT>&nbsp;</DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <DIV dir=ltr><FONT face=Arial size=2><SPAN 
  class=232385200-07052005></SPAN></FONT><FONT face=Arial size=2><SPAN 
  class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;DOMTestDocumentBuilderFactory 
  factory1 =<BR>&nbsp; &nbsp; new 
  JAXPDOMTestDocumentBuilderFactory(null,<BR>&nbsp;&nbsp;&nbsp; 
  JAXPDOMTestDocumentBuilderFactory.<U>getConfiguration1());</U><BR></DIV></SPAN></FONT><FONT 
  face=Arial size=2><SPAN class=232385200-07052005></SPAN></FONT>
  <DIV dir=ltr><FONT face=Arial size=2><SPAN 
  class=232385200-07052005>&nbsp;&nbsp;&nbsp; 
  printPrologue();<BR>&nbsp;&nbsp;&nbsp; 
  printImplementation(factory1);<BR>&nbsp;&nbsp;&nbsp; 
  printAttributes(factory1);<BR>&nbsp;&nbsp;&nbsp; int result1 = 
  runTest(testConstructor, factory1);</SPAN></FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV dir=ltr><FONT face=Arial size=2><SPAN 
  class=232385200-07052005>&nbsp;&nbsp;&nbsp; DOMTestDocumentBuilderFactory 
  factory2 =<BR>&nbsp;&nbsp;&nbsp; new 
  JAXPDOMTestDocumentBuilderFactory(null,<BR>&nbsp;&nbsp;&nbsp;JAXPDOMTestDocumentBuilderFactory.<U>getConfiguration2());<BR></U></SPAN></FONT><FONT 
  face=Arial size=2><SPAN class=232385200-07052005></SPAN></FONT></DIV>
  <DIV dir=ltr><FONT face=Arial size=2><SPAN 
  class=232385200-07052005>&nbsp;&nbsp;&nbsp; 
  printAttributes(factory2);<BR>&nbsp;&nbsp;&nbsp; int result2 = 
  runTest(testConstructor, factory2);<BR>&nbsp;&nbsp;&nbsp; if(result1 != 0) 
  {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  System.exit(result1);<BR>&nbsp;&nbsp;&nbsp; }<BR>&nbsp;&nbsp;&nbsp; 
  System.exit(result2);<BR></DIV></BLOCKQUOTE></SPAN></FONT>
<DIV dir=ltr><FONT face=Arial size=2><SPAN 
class=232385200-07052005>3)&nbsp;&nbsp;<U>QUESTION 3 :</U><U>&nbsp; Is Level 3 
-Events test suites available yet ?</U>&nbsp;&nbsp;In trying to find 
Dom-L3-Events, I</SPAN></FONT><FONT face=Arial size=2><SPAN 
class=232385200-07052005> downloaded the <U>"Dom3-core-tests-20040405"</U> zip 
file at <A 
href="http://www.w3.org/DOM/Test/">http://www.w3.org/DOM/Test/</A>.&nbsp;</SPAN></FONT></DIV>
<DIV dir=ltr><FONT face=Arial size=2><SPAN 
class=232385200-07052005>&nbsp;&nbsp;&nbsp;&nbsp;</SPAN></FONT></DIV>
<DIV dir=ltr><FONT face=Arial size=2><SPAN 
class=232385200-07052005>&nbsp;&nbsp;&nbsp; &nbsp;Unzip and in there I 
found&nbsp;Level-2 Events but NOT Level-3-Events </SPAN></FONT><FONT face=Arial 
size=2><SPAN class=232385200-07052005>&nbsp;&nbsp;?&nbsp;&nbsp; (C:\ 
Dom3-core-tests-20040405 \ org \ w3c \ domts \ <U>level2 \ 
events)</U></SPAN></FONT></DIV>
<DIV dir=ltr><FONT face=Arial size=2><SPAN 
class=232385200-07052005><U></U></SPAN></FONT>&nbsp;</DIV>
<DIV dir=ltr><FONT face=Arial size=2><SPAN 
class=232385200-07052005>4)&nbsp;</SPAN></FONT><FONT face=Arial size=2><SPAN 
class=232385200-07052005> <U>QUESTION 4 :</U> There are references to 
"alltests"&nbsp; called in&nbsp;many test suites (Test suites : 
TestDefaultParser , TestBatik.... etc as below...) , yet&nbsp; I COULD NOT find 
their&nbsp;respective <STRONG><FONT 
color=#ff0000>level2.events.alltests.</FONT></STRONG>"alltests.java".&nbsp;&nbsp;In 
the zip file mentioned above,&nbsp;I saw<FONT face=Arial size=2><SPAN 
class=232385200-07052005> class "alltests.java" exist ONLY in package 
"org.w3c.domts.level3.core".</SPAN></FONT></SPAN></FONT><FONT face=Arial 
size=2><SPAN class=232385200-07052005><FONT face=Arial size=2><SPAN 
class=232385200-07052005>&nbsp;&nbsp;&nbsp;Is&nbsp;this class&nbsp; 
mis-placed&nbsp;? </SPAN></FONT>May be this is related to java classloader but 
please excuse me&nbsp;if this is trivial question and help me 
understand.</SPAN></FONT></DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <DIV dir=ltr><FONT face=Arial size=2><SPAN class=232385200-07052005>public 
  class <U>TestDefaultParser</U> extends TestSuite {</SPAN></FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV dir=ltr><FONT face=Arial size=2><SPAN class=232385200-07052005>&nbsp; 
  public static TestSuite suite() throws Exception<BR>&nbsp; 
  {<BR>&nbsp;&nbsp;&nbsp; Class testClass = 
  ClassLoader.getSystemClassLoader().loadClass("org.w3c.domts.<STRONG><FONT 
  color=#ff0000>level2.events.alltests</FONT></STRONG>");<BR>&nbsp;&nbsp;&nbsp; 
  Constructor testConstructor = testClass.getConstructor(new Class[] { 
  DOMTestDocumentBuilderFactory.class });</SPAN></FONT></DIV></BLOCKQUOTE>
<DIV><FONT face=Arial size=2><SPAN 
class=232385200-07052005></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN class=232385200-07052005>Best 
regards</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=232385200-07052005>-Elise 
Nguyen</SPAN></FONT></DIV></BODY></HTML>

--Boundary_(ID_EiWX4o3D2dOyDc6BVFA2HQ)--