You are viewing a plain text version of this content. The canonical link for it is here.
Posted to doxia-commits@maven.apache.org by vs...@apache.org on 2008/12/11 02:17:40 UTC

svn commit: r725514 - in /maven/doxia/doxia/trunk: doxia-core/ doxia-core/src/test/java/org/apache/maven/doxia/xsd/ doxia-modules/doxia-module-fml/ doxia-modules/doxia-module-fml/src/test/java/org/apache/maven/doxia/module/fml/ doxia-modules/doxia-modu...

Author: vsiveton
Date: Wed Dec 10 17:17:38 2008
New Revision: 725514

URL: http://svn.apache.org/viewvc?rev=725514&view=rev
Log:
o updated XML validation test cases according comments on dev@
o removed SCM dependencies
o added dependency on the new module doxia-test-docs

Modified:
    maven/doxia/doxia/trunk/doxia-core/pom.xml
    maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidatorTest.java
    maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/pom.xml
    maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/src/test/java/org/apache/maven/doxia/module/fml/FmlValidatorTest.java
    maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/pom.xml
    maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/src/test/java/org/apache/maven/doxia/module/xdoc/XdocValidatorTest.java

Modified: maven/doxia/doxia/trunk/doxia-core/pom.xml
URL: http://svn.apache.org/viewvc/maven/doxia/doxia/trunk/doxia-core/pom.xml?rev=725514&r1=725513&r2=725514&view=diff
==============================================================================
--- maven/doxia/doxia/trunk/doxia-core/pom.xml (original)
+++ maven/doxia/doxia/trunk/doxia-core/pom.xml Wed Dec 10 17:17:38 2008
@@ -56,30 +56,6 @@
     </dependency>
 
     <!-- test -->
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-api</artifactId>
-      <version>1.1</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-manager-plexus</artifactId>
-      <version>1.1</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-provider-svn-commons</artifactId>
-      <version>1.1</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-provider-svnexe</artifactId>
-      <version>1.1</version>
-      <scope>test</scope>
-    </dependency>
   </dependencies>
 
   <build>

Modified: maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidatorTest.java
URL: http://svn.apache.org/viewvc/maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidatorTest.java?rev=725514&r1=725513&r2=725514&view=diff
==============================================================================
--- maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidatorTest.java (original)
+++ maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidatorTest.java Wed Dec 10 17:17:38 2008
@@ -19,22 +19,28 @@
  * under the License.
  */
 
-import java.io.File;
 import java.io.IOException;
-import java.io.Reader;
+import java.io.InputStream;
 import java.io.StringReader;
+import java.net.JarURLConnection;
+import java.net.URL;
 import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Enumeration;
+import java.util.Hashtable;
 import java.util.Iterator;
 import java.util.List;
+import java.util.Locale;
+import java.util.Map;
+import java.util.jar.JarEntry;
+import java.util.jar.JarFile;
 
 import junit.framework.AssertionFailedError;
 
 import org.apache.maven.doxia.parser.AbstractXmlParser;
-import org.apache.maven.scm.ScmFileSet;
-import org.apache.maven.scm.manager.ScmManager;
 import org.codehaus.plexus.PlexusTestCase;
 import org.codehaus.plexus.util.IOUtil;
-import org.codehaus.plexus.util.ReaderFactory;
+import org.codehaus.plexus.util.SelectorUtils;
 import org.xml.sax.InputSource;
 import org.xml.sax.SAXException;
 import org.xml.sax.SAXNotRecognizedException;
@@ -57,29 +63,20 @@
     /** The vm line separator */
     protected static final String EOL = System.getProperty( "line.separator" );
 
+    /** Simple cache mechanism to load test documents. */
+    private static final Map CACHE_DOXIA_TEST_DOCUMENTS = new Hashtable();
+
+    /** Maven resource in the doxia-test-docs-XXX.jar */
+    private static final String MAVEN_RESOURCE_PATH = "META-INF/maven/org.apache.maven.doxia/doxia-test-docs/";
+
     /** XMLReader to validate xml file */
     private XMLReader xmlReader;
 
-    /** The scm manager */
-    private ScmManager scmManager;
-
     /** {@inheritDoc} */
     protected void setUp()
         throws Exception
     {
         super.setUp();
-
-        for ( Iterator it = getScmRepositoryWrapper().iterator(); it.hasNext(); )
-        {
-            ScmRepositoryWrapper wrapper = (ScmRepositoryWrapper) it.next();
-
-            if ( !wrapper.getCheckoutDir().exists() )
-            {
-                wrapper.getCheckoutDir().mkdirs();
-                getScmManager().checkOut( getScmManager().makeScmRepository( wrapper.getScmRepository() ),
-                                          new ScmFileSet( wrapper.getCheckoutDir() ) );
-            }
-        }
     }
 
     /** {@inheritDoc} */
@@ -88,23 +85,14 @@
     {
         super.tearDown();
 
-        scmManager = null;
-
         xmlReader = null;
     }
 
     /**
-     * @return non null list of ScmRepositoryWrapper
+     * @return a non null patterns to includes specific test files.
+     * @see AbstractXmlValidatorTest#getTestDocuments()
      */
-    protected abstract List getScmRepositoryWrapper();
-
-    /**
-     * @param wrapper not null
-     * @return a list of files in a given wrapper to be validated
-     * @throws IOException if any
-     */
-    protected abstract List getXmlFiles( ScmRepositoryWrapper wrapper )
-        throws IOException;
+    protected abstract String[] getIncludes();
 
     /**
      * @param content xml content not null
@@ -120,38 +108,42 @@
     public void testXmlFilesWithDoxiaNamespaces()
         throws Exception
     {
-        for ( Iterator it = getScmRepositoryWrapper().iterator(); it.hasNext(); )
+        for ( Iterator it = getTestDocuments().entrySet().iterator(); it.hasNext(); )
         {
-            ScmRepositoryWrapper wrapper = (ScmRepositoryWrapper) it.next();
+            Map.Entry entry = (Map.Entry) it.next();
 
-            for ( Iterator it2 = getXmlFiles( wrapper ).iterator(); it2.hasNext(); )
+            if ( getContainer().getLogger().isDebugEnabled() )
             {
-                File f = (File) it2.next();
+                getContainer().getLogger().debug( "Validate '" + entry.getKey() + "'" );
+            }
 
-                List errors = parseXML( f );
+            List errors = parseXML( entry.getValue().toString() );
 
-                for ( Iterator it3 = errors.iterator(); it3.hasNext(); )
-                {
-                    String message = (String) it3.next();
+            for ( Iterator it2 = errors.iterator(); it2.hasNext(); )
+            {
+                String message = (String) it2.next();
 
-                    if ( message.length() != 0 )
+                if ( message.length() != 0 )
+                {
+                    // Exclude some xhtml errors
+                    if ( message
+                                .indexOf( "schema_reference.4: Failed to read schema document 'http://www.w3.org/2001/xml.xsd'" ) == -1
+                        && message
+                                  .indexOf( "Message: cvc-complex-type.4: Attribute 'alt' must appear on element 'img'." ) == -1
+                        && message
+                                  .indexOf( "Message: cvc-complex-type.2.4.a: Invalid content starting with element" ) == -1
+                        && message
+                                  .indexOf( "Message: cvc-complex-type.2.4.a: Invalid content was found starting with element" ) == -1
+                        && message.indexOf( "Message: cvc-datatype-valid.1.2.1:" ) == -1 // Doxia allow space
+                        && message.indexOf( "Message: cvc-attribute.3:" ) == -1 ) // Doxia allow space
                     {
-                        // Exclude some xhtml errors
-                        if ( message.indexOf( "schema_reference.4: Failed to read schema document 'http://www.w3.org/2001/xml.xsd'" ) == -1
-                            && message.indexOf( "Message: cvc-complex-type.4: Attribute 'alt' must appear on element 'img'." ) == -1
-                            && message.indexOf( "Message: cvc-complex-type.2.4.a: Invalid content starting with element" ) == -1
-                            && message.indexOf( "Message: cvc-complex-type.2.4.a: Invalid content was found starting with element" ) == -1
-                            && message.indexOf( "Message: cvc-datatype-valid.1.2.1:" ) == -1  // Doxia allow space
-                            && message.indexOf( "Message: cvc-attribute.3:" ) == -1 ) // Doxia allow space
-                        {
-                            fail( f.getAbsolutePath() + EOL + message );
-                        }
-                        else
+                        fail( entry.getKey() + EOL + message );
+                    }
+                    else
+                    {
+                        if ( getContainer().getLogger().isDebugEnabled() )
                         {
-                            if ( getContainer().getLogger().isDebugEnabled() )
-                            {
-                                getContainer().getLogger().debug( f.getAbsolutePath() + EOL + message );
-                            }
+                            getContainer().getLogger().debug( entry.getKey() + EOL + message );
                         }
                     }
                 }
@@ -163,17 +155,6 @@
     // Private method
     // ----------------------------------------------------------------------
 
-    private ScmManager getScmManager()
-        throws Exception
-    {
-        if ( scmManager == null )
-        {
-            scmManager = (ScmManager) lookup( ScmManager.ROLE );
-        }
-
-        return scmManager;
-    }
-
     private XMLReader getXMLReader()
     {
         if ( xmlReader == null )
@@ -205,17 +186,14 @@
         return xmlReader;
     }
 
-    private List parseXML( File f )
+    private List parseXML( String xmlContent )
         throws IOException, SAXException
     {
-        Reader reader = ReaderFactory.newXmlReader( f );
-        String content = IOUtil.toString( reader );
-        IOUtil.close( reader );
-        content = addNamespaces( content );
+        xmlContent = addNamespaces( xmlContent );
 
         MessagesErrorHandler errorHandler = (MessagesErrorHandler) getXMLReader().getErrorHandler();
 
-        getXMLReader().parse( new InputSource( new StringReader( content ) ) );
+        getXMLReader().parse( new InputSource( new StringReader( xmlContent ) ) );
 
         return errorHandler.getMessages();
     }
@@ -271,32 +249,92 @@
         }
     }
 
-    protected static class ScmRepositoryWrapper
+    /**
+     * @return a map of test resources filtered by patterns from {@link #getIncludes()}.
+     * @throws IOException if any
+     * @see #getIncludes()
+     * @see #getAllTestDocuments()
+     */
+    protected Map getTestDocuments()
+        throws IOException
     {
-        private final String scmRepository;
+        if ( getIncludes() == null )
+        {
+            return Collections.EMPTY_MAP;
+        }
 
-        private final File checkoutDir;
+        Map testDocs = getAllTestDocuments();
+        Map ret = new Hashtable();
+        ret.putAll( testDocs );
+        for ( Iterator it = testDocs.keySet().iterator(); it.hasNext(); )
+        {
+            String key = it.next().toString();
 
-        public ScmRepositoryWrapper( String scmRepository, File checkoutDir )
+            for (int i = 0; i < getIncludes().length; i++)
+            {
+                if ( !SelectorUtils.matchPath( getIncludes()[i], key.toLowerCase( Locale.ENGLISH ) ) )
+                {
+                    ret.remove( key );
+                }
+            }
+        }
+
+        return ret;
+    }
+
+    /**
+     * Find test resources in the <code>doxia-test-docs-XXX.jar</code>
+     *
+     * @return a map of test resources defined as follow:
+     * <ul>
+     *   <li>key, the full url of test documents, i.e. <code>jar:file:/.../doxia-test-docs-XXX.jar!/path/to/resource</code></li>
+     *   <li>value, the content for the resource defined by the key</li>
+     * </ul>
+     * @throws IOException if any
+     */
+    protected static Map getAllTestDocuments()
+        throws IOException
+    {
+        if ( CACHE_DOXIA_TEST_DOCUMENTS != null && !CACHE_DOXIA_TEST_DOCUMENTS.isEmpty() )
         {
-            this.scmRepository = scmRepository;
-            this.checkoutDir = checkoutDir;
+            return CACHE_DOXIA_TEST_DOCUMENTS;
         }
 
-        /**
-         * @return the scmRepository
-         */
-        public String getScmRepository()
+        URL testJar = AbstractXmlValidatorTest.class.getClassLoader().getResource( MAVEN_RESOURCE_PATH );
+        if ( testJar == null )
         {
-            return scmRepository;
+            throw new RuntimeException(
+                                        "Could not find the Doxia test documents artefact i.e. doxia-test-docs-XXX.jar" );
         }
 
-        /**
-         * @return the checkoutDir
-         */
-        public File getCheckoutDir()
+        JarURLConnection conn = (JarURLConnection) testJar.openConnection();
+        JarFile jarFile = conn.getJarFile();
+        for ( Enumeration e = jarFile.entries(); e.hasMoreElements(); )
         {
-            return checkoutDir;
+            JarEntry entry = (JarEntry) e.nextElement();
+
+            if ( entry.getName().startsWith( "META-INF" ) )
+            {
+                continue;
+            }
+            if ( entry.isDirectory() )
+            {
+                continue;
+            }
+
+            InputStream in = null;
+            try
+            {
+                in = AbstractXmlValidatorTest.class.getClassLoader().getResource( entry.getName() ).openStream();
+                String content = IOUtil.toString( in );
+                CACHE_DOXIA_TEST_DOCUMENTS.put( "jar:" + conn.getJarFileURL() + "!/" + entry.getName(), content );
+            }
+            finally
+            {
+                IOUtil.close( in );
+            }
         }
+
+        return CACHE_DOXIA_TEST_DOCUMENTS;
     }
 }

Modified: maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/pom.xml
URL: http://svn.apache.org/viewvc/maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/pom.xml?rev=725514&r1=725513&r2=725514&view=diff
==============================================================================
--- maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/pom.xml (original)
+++ maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/pom.xml Wed Dec 10 17:17:38 2008
@@ -41,33 +41,14 @@
 
     <!-- test -->
     <dependency>
-      <groupId>xerces</groupId>
-      <artifactId>xercesImpl</artifactId>
-      <version>2.8.1</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-api</artifactId>
-      <version>1.1</version>
+      <groupId>org.apache.maven.doxia</groupId>
+      <artifactId>doxia-test-docs</artifactId>
       <scope>test</scope>
     </dependency>
     <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-manager-plexus</artifactId>
-      <version>1.1</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-provider-svn-commons</artifactId>
-      <version>1.1</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-provider-svnexe</artifactId>
-      <version>1.1</version>
+      <groupId>xerces</groupId>
+      <artifactId>xercesImpl</artifactId>
+      <version>2.8.1</version>
       <scope>test</scope>
     </dependency>
   </dependencies>

Modified: maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/src/test/java/org/apache/maven/doxia/module/fml/FmlValidatorTest.java
URL: http://svn.apache.org/viewvc/maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/src/test/java/org/apache/maven/doxia/module/fml/FmlValidatorTest.java?rev=725514&r1=725513&r2=725514&view=diff
==============================================================================
--- maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/src/test/java/org/apache/maven/doxia/module/fml/FmlValidatorTest.java (original)
+++ maven/doxia/doxia/trunk/doxia-modules/doxia-module-fml/src/test/java/org/apache/maven/doxia/module/fml/FmlValidatorTest.java Wed Dec 10 17:17:38 2008
@@ -20,14 +20,10 @@
  */
 
 import java.io.File;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
 
 import org.apache.maven.doxia.xsd.AbstractXmlValidatorTest;
-import org.codehaus.plexus.util.FileUtils;
 import org.codehaus.plexus.util.StringUtils;
 
 /**
@@ -58,166 +54,9 @@
     }
 
     /** {@inheritDoc} */
-    protected List getScmRepositoryWrapper()
+    protected String[] getIncludes()
     {
-        List l = new ArrayList();
-
-        l.add( new ScmRepositoryWrapper( "scm:svn:http://svn.apache.org/repos/asf/maven/site/trunk/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-site/fml" ) ) );
-        l.add( new ScmRepositoryWrapper( "scm:svn:http://svn.apache.org/repos/asf/maven/doxia/site/src/site/fml",
-                                         new File( getBasedir(), "target/svn/doxia-site/fml" ) ) );
-
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-ant-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-ant-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-antrun-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-antrun-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-assembly-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-assembly-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-changelog-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-changelog-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-changes-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-changes-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-checkstyle-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-checkstyle-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-clean-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-clean-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-compiler-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-compiler-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-dependency-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-dependency-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-deploy-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-deploy-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-doap-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-doap-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-docck-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-docck-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-ear-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-ear-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-ejb-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-ejb-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-gpg-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-gpg-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-help-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-help-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-idea-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-idea-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-install-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-install-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-invoker-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-invoker-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-jar-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-jar-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-javadoc-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-javadoc-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-one-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-one-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-patch-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-patch-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-pmd-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-pmd-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-project-info-reports-plugin/src/site/fml",
-                                         new File( getBasedir(),
-                                                   "target/svn/maven-project-info-reports-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-rar-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-rar-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-remote-resources-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-remote-resources-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-repository-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-repository-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-ressources-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-ressources-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-site-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-site-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-source-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-source-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-stage-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-stage-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-stage-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-stage-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-verifier-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-verifier-plugin/fml" ) ) );
-        l
-         .add( new ScmRepositoryWrapper(
-                                         "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-war-plugin/src/site/fml",
-                                         new File( getBasedir(), "target/svn/maven-war-plugin/fml" ) ) );
-
-        return l;
-    }
-
-    /** {@inheritDoc} */
-    protected List getXmlFiles( ScmRepositoryWrapper wrapper )
-        throws IOException
-    {
-        return FileUtils.getFiles( wrapper.getCheckoutDir(), "**/*.fml",
-                                   StringUtils.concatenate( FileUtils.getDefaultExcludes() ) );
+        return new String[] { "**/*.fml" };
     }
 
     /** {@inheritDoc} */

Modified: maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/pom.xml
URL: http://svn.apache.org/viewvc/maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/pom.xml?rev=725514&r1=725513&r2=725514&view=diff
==============================================================================
--- maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/pom.xml (original)
+++ maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/pom.xml Wed Dec 10 17:17:38 2008
@@ -41,33 +41,14 @@
 
     <!-- test -->
     <dependency>
-      <groupId>xerces</groupId>
-      <artifactId>xercesImpl</artifactId>
-      <version>2.8.1</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-api</artifactId>
-      <version>1.1</version>
+      <groupId>org.apache.maven.doxia</groupId>
+      <artifactId>doxia-test-docs</artifactId>
       <scope>test</scope>
     </dependency>
     <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-manager-plexus</artifactId>
-      <version>1.1</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-provider-svn-commons</artifactId>
-      <version>1.1</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.maven.scm</groupId>
-      <artifactId>maven-scm-provider-svnexe</artifactId>
-      <version>1.1</version>
+      <groupId>xerces</groupId>
+      <artifactId>xercesImpl</artifactId>
+      <version>2.8.1</version>
       <scope>test</scope>
     </dependency>
   </dependencies>

Modified: maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/src/test/java/org/apache/maven/doxia/module/xdoc/XdocValidatorTest.java
URL: http://svn.apache.org/viewvc/maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/src/test/java/org/apache/maven/doxia/module/xdoc/XdocValidatorTest.java?rev=725514&r1=725513&r2=725514&view=diff
==============================================================================
--- maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/src/test/java/org/apache/maven/doxia/module/xdoc/XdocValidatorTest.java (original)
+++ maven/doxia/doxia/trunk/doxia-modules/doxia-module-xdoc/src/test/java/org/apache/maven/doxia/module/xdoc/XdocValidatorTest.java Wed Dec 10 17:17:38 2008
@@ -20,14 +20,10 @@
  */
 
 import java.io.File;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
 
 import org.apache.maven.doxia.xsd.AbstractXmlValidatorTest;
-import org.codehaus.plexus.util.FileUtils;
 import org.codehaus.plexus.util.StringUtils;
 
 /**
@@ -58,27 +54,9 @@
     }
 
     /** {@inheritDoc} */
-    protected List getScmRepositoryWrapper()
+    protected String[] getIncludes()
     {
-        List l = new ArrayList();
-
-        l.add( new ScmRepositoryWrapper( "scm:svn:http://svn.apache.org/repos/asf/maven/site/trunk/src/site/xdoc",
-                                         new File( getBasedir(), "target/svn/maven-site/xdoc" ) ) );
-        l.add( new ScmRepositoryWrapper( "scm:svn:http://svn.apache.org/repos/asf/maven/doxia/site/src/site/xdoc",
-                                         new File( getBasedir(), "target/svn/doxia-site/xdoc" ) ) );
-
-        l.add( new ScmRepositoryWrapper( "scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-site-plugin/src/site/xdoc",
-                                         new File( getBasedir(), "target/svn/maven-site-plugin/xdoc" ) ) );
-
-        return l;
-    }
-
-    /** {@inheritDoc} */
-    protected List getXmlFiles( ScmRepositoryWrapper wrapper )
-        throws IOException
-    {
-        return FileUtils.getFiles( wrapper.getCheckoutDir(), "**/*.xml, **/*.xdoc",
-                                   StringUtils.concatenate( FileUtils.getDefaultExcludes() ) );
+        return new String[] { "**/*.xml", "**/xdoc/*" };
     }
 
     /** {@inheritDoc} */