You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by ma...@apache.org on 2007/07/02 18:06:24 UTC
svn commit: r552524 [7/9] - in /maven/plugins/trunk/maven-dependency-plugin:
./ src/changes/ src/it/copy-dependencies/ src/it/copy-dependencies2/
src/it/mdep-27/ src/it/mdep-50/ src/it/mdep-61/ src/it/mdep-66/
src/it/mdep-67/ src/main/java/org/apache/m...
Modified: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/AbstractArtifactFeatureFilterTestCase.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/AbstractArtifactFeatureFilterTestCase.java?view=diff&rev=552524&r1=552523&r2=552524
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/AbstractArtifactFeatureFilterTestCase.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/AbstractArtifactFeatureFilterTestCase.java Mon Jul 2 09:06:19 2007
@@ -1,139 +1,139 @@
-package org.apache.maven.plugin.dependency.testUtils;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-/**
- *
- */
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-import junit.framework.TestCase;
-
-import org.apache.maven.plugin.dependency.utils.filters.AbstractArtifactFeatureFilter;
-import org.apache.maven.plugin.logging.Log;
-import org.apache.maven.plugin.testing.SilentLog;
-
-/**
- * Abstract test case for subclasses of AbstractArtifactFeatureFilter
- *
- * @author clove
- * @see junit.framework.TestCase
- * @see org.apache.maven.plugin.dependency.utils.filters.AbstractArtifactFeatureFilter
- * @since 2.0
- */
-public abstract class AbstractArtifactFeatureFilterTestCase
- extends TestCase
-{
- protected Set artifacts = new HashSet();
-
- Log log = new SilentLog();
-
- protected Class filterClass;
-
- protected void setUp()
- throws Exception
- {
- super.setUp();
-
- }
-
- private Object createObjectViaReflection( Class clazz, Object[] conArgs )
- throws SecurityException, NoSuchMethodException, IllegalArgumentException, InstantiationException,
- IllegalAccessException, InvocationTargetException
- {
- Class[] argslist = new Class[2];
- argslist[0] = String.class;
- argslist[1] = String.class;
- Constructor ct = clazz.getConstructor( argslist );
- return ct.newInstance( conArgs );
- }
-
- public abstract void testParsing()
- throws Exception;
-
- public void parsing()
- throws SecurityException, NoSuchMethodException, IllegalArgumentException, InstantiationException,
- IllegalAccessException, InvocationTargetException
- {
- Object[] conArgs = new Object[] { "one,two", "three,four," };
-
- AbstractArtifactFeatureFilter filter = (AbstractArtifactFeatureFilter) createObjectViaReflection( filterClass,
- conArgs );
- List includes = filter.getIncludes();
- List excludes = filter.getExcludes();
-
- assertEquals( 2, includes.size() );
- assertEquals( 2, excludes.size() );
- assertEquals( "one", includes.get( 0 ).toString() );
- assertEquals( "two", includes.get( 1 ).toString() );
- assertEquals( "three", excludes.get( 0 ).toString() );
- assertEquals( "four", excludes.get( 1 ).toString() );
- }
-
- public abstract void testFiltering()
- throws Exception;
-
- public Set filtering()
- throws SecurityException, IllegalArgumentException, NoSuchMethodException, InstantiationException,
- IllegalAccessException, InvocationTargetException
- {
- Object[] conArgs = new Object[] { "one,two", "one,three," };
- AbstractArtifactFeatureFilter filter = (AbstractArtifactFeatureFilter) createObjectViaReflection( filterClass,
- conArgs );
- Set result = filter.filter( artifacts, log );
- assertEquals( 1, result.size() );
- return result;
- }
-
- public abstract void testFiltering2()
- throws Exception;
-
- public Set filtering2()
- throws SecurityException, IllegalArgumentException, NoSuchMethodException, InstantiationException,
- IllegalAccessException, InvocationTargetException
- {
- Object[] conArgs = new Object[] { null, "one,three," };
- AbstractArtifactFeatureFilter filter = (AbstractArtifactFeatureFilter) createObjectViaReflection( filterClass,
- conArgs );
- Set result = filter.filter( artifacts, log );
- assertEquals( 2, result.size() );
- return result;
-
- }
-
- public abstract void testFiltering3()
- throws Exception;
-
- public void filtering3()
- throws SecurityException, IllegalArgumentException, NoSuchMethodException, InstantiationException,
- IllegalAccessException, InvocationTargetException
- {
- Object[] conArgs = new Object[] { null, null };
- AbstractArtifactFeatureFilter filter = (AbstractArtifactFeatureFilter) createObjectViaReflection( filterClass,
- conArgs );
- Set result = filter.filter( artifacts, log );
- assertEquals( 4, result.size() );
- }
-}
+package org.apache.maven.plugin.dependency.testUtils;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ *
+ */
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+
+import junit.framework.TestCase;
+
+import org.apache.maven.plugin.dependency.utils.filters.AbstractArtifactFeatureFilter;
+import org.apache.maven.plugin.logging.Log;
+import org.apache.maven.plugin.testing.SilentLog;
+
+/**
+ * Abstract test case for subclasses of AbstractArtifactFeatureFilter
+ *
+ * @author clove
+ * @see junit.framework.TestCase
+ * @see org.apache.maven.plugin.dependency.utils.filters.AbstractArtifactFeatureFilter
+ * @since 2.0
+ */
+public abstract class AbstractArtifactFeatureFilterTestCase
+ extends TestCase
+{
+ protected Set artifacts = new HashSet();
+
+ Log log = new SilentLog();
+
+ protected Class filterClass;
+
+ protected void setUp()
+ throws Exception
+ {
+ super.setUp();
+
+ }
+
+ private Object createObjectViaReflection( Class clazz, Object[] conArgs )
+ throws SecurityException, NoSuchMethodException, IllegalArgumentException, InstantiationException,
+ IllegalAccessException, InvocationTargetException
+ {
+ Class[] argslist = new Class[2];
+ argslist[0] = String.class;
+ argslist[1] = String.class;
+ Constructor ct = clazz.getConstructor( argslist );
+ return ct.newInstance( conArgs );
+ }
+
+ public abstract void testParsing()
+ throws Exception;
+
+ public void parsing()
+ throws SecurityException, NoSuchMethodException, IllegalArgumentException, InstantiationException,
+ IllegalAccessException, InvocationTargetException
+ {
+ Object[] conArgs = new Object[] { "one,two", "three,four," };
+
+ AbstractArtifactFeatureFilter filter = (AbstractArtifactFeatureFilter) createObjectViaReflection( filterClass,
+ conArgs );
+ List includes = filter.getIncludes();
+ List excludes = filter.getExcludes();
+
+ assertEquals( 2, includes.size() );
+ assertEquals( 2, excludes.size() );
+ assertEquals( "one", includes.get( 0 ).toString() );
+ assertEquals( "two", includes.get( 1 ).toString() );
+ assertEquals( "three", excludes.get( 0 ).toString() );
+ assertEquals( "four", excludes.get( 1 ).toString() );
+ }
+
+ public abstract void testFiltering()
+ throws Exception;
+
+ public Set filtering()
+ throws SecurityException, IllegalArgumentException, NoSuchMethodException, InstantiationException,
+ IllegalAccessException, InvocationTargetException
+ {
+ Object[] conArgs = new Object[] { "one,two", "one,three," };
+ AbstractArtifactFeatureFilter filter = (AbstractArtifactFeatureFilter) createObjectViaReflection( filterClass,
+ conArgs );
+ Set result = filter.filter( artifacts, log );
+ assertEquals( 1, result.size() );
+ return result;
+ }
+
+ public abstract void testFiltering2()
+ throws Exception;
+
+ public Set filtering2()
+ throws SecurityException, IllegalArgumentException, NoSuchMethodException, InstantiationException,
+ IllegalAccessException, InvocationTargetException
+ {
+ Object[] conArgs = new Object[] { null, "one,three," };
+ AbstractArtifactFeatureFilter filter = (AbstractArtifactFeatureFilter) createObjectViaReflection( filterClass,
+ conArgs );
+ Set result = filter.filter( artifacts, log );
+ assertEquals( 2, result.size() );
+ return result;
+
+ }
+
+ public abstract void testFiltering3()
+ throws Exception;
+
+ public void filtering3()
+ throws SecurityException, IllegalArgumentException, NoSuchMethodException, InstantiationException,
+ IllegalAccessException, InvocationTargetException
+ {
+ Object[] conArgs = new Object[] { null, null };
+ AbstractArtifactFeatureFilter filter = (AbstractArtifactFeatureFilter) createObjectViaReflection( filterClass,
+ conArgs );
+ Set result = filter.filter( artifacts, log );
+ assertEquals( 4, result.size() );
+ }
+}
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/AbstractArtifactFeatureFilterTestCase.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/AbstractArtifactFeatureFilterTestCase.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Mon Jul 2 09:06:19 2007
@@ -1 +1 @@
-Author Date Id HeadURL Revision
+Author Date Id Revision
Modified: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyArtifactStubFactory.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyArtifactStubFactory.java?view=diff&rev=552524&r1=552523&r2=552524
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyArtifactStubFactory.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyArtifactStubFactory.java Mon Jul 2 09:06:19 2007
@@ -1,61 +1,61 @@
-package org.apache.maven.plugin.dependency.testUtils;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import java.io.File;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Iterator;
-
-import org.apache.maven.artifact.Artifact;
-import org.apache.maven.plugin.dependency.fromConfiguration.ArtifactItem;
-import org.apache.maven.plugin.testing.ArtifactStubFactory;
-
-public class DependencyArtifactStubFactory
-extends ArtifactStubFactory
-{
-
- /**
- * @param theWorkingDir
- * @param theCreateFiles
- */
- public DependencyArtifactStubFactory( File theWorkingDir, boolean theCreateFiles )
- {
- super( theWorkingDir, theCreateFiles );
- }
-
- public ArtifactItem getArtifactItem( Artifact artifact )
- {
- ArtifactItem item = new ArtifactItem( artifact );
- return item;
- }
-
- public ArrayList getArtifactItems( Collection artifacts )
- {
- ArrayList list = new ArrayList();
- Iterator iter = artifacts.iterator();
- while ( iter.hasNext() )
- {
- list.add( getArtifactItem( (Artifact) iter.next() ) );
- }
- return list;
- }
-
- }
+package org.apache.maven.plugin.dependency.testUtils;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+
+import org.apache.maven.artifact.Artifact;
+import org.apache.maven.plugin.dependency.fromConfiguration.ArtifactItem;
+import org.apache.maven.plugin.testing.ArtifactStubFactory;
+
+public class DependencyArtifactStubFactory
+extends ArtifactStubFactory
+{
+
+ /**
+ * @param theWorkingDir
+ * @param theCreateFiles
+ */
+ public DependencyArtifactStubFactory( File theWorkingDir, boolean theCreateFiles )
+ {
+ super( theWorkingDir, theCreateFiles );
+ }
+
+ public ArtifactItem getArtifactItem( Artifact artifact )
+ {
+ ArtifactItem item = new ArtifactItem( artifact );
+ return item;
+ }
+
+ public ArrayList getArtifactItems( Collection artifacts )
+ {
+ ArrayList list = new ArrayList();
+ Iterator iter = artifacts.iterator();
+ while ( iter.hasNext() )
+ {
+ list.add( getArtifactItem( (Artifact) iter.next() ) );
+ }
+ return list;
+ }
+
+ }
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyArtifactStubFactory.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyArtifactStubFactory.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Mon Jul 2 09:06:19 2007
@@ -1 +1 @@
-Author Date Id HeadURL Revision
+Author Date Id Revision
Modified: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyTestUtils.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyTestUtils.java?view=diff&rev=552524&r1=552523&r2=552524
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyTestUtils.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyTestUtils.java Mon Jul 2 09:06:19 2007
@@ -1,111 +1,111 @@
-package org.apache.maven.plugin.dependency.testUtils;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import java.io.File;
-import java.io.IOException;
-import java.lang.reflect.Field;
-import java.util.HashMap;
-
-import org.apache.maven.artifact.factory.ArtifactFactory;
-import org.apache.maven.artifact.factory.DefaultArtifactFactory;
-import org.apache.maven.artifact.handler.manager.ArtifactHandlerManager;
-import org.apache.maven.artifact.handler.manager.DefaultArtifactHandlerManager;
-import org.apache.maven.plugin.MojoExecutionException;
-import org.apache.maven.plugin.logging.Log;
-import org.apache.maven.plugin.testing.SilentLog;
-import org.apache.maven.shared.model.fileset.FileSet;
-import org.apache.maven.shared.model.fileset.util.FileSetManager;
-import org.codehaus.plexus.util.ReflectionUtils;
-
-public class DependencyTestUtils
-{
-
- /**
- * Deletes a directory and its contents.
- *
- * @param dir
- * The base directory of the included and excluded files.
- * @throws IOException
- * @throws MojoExecutionException
- * When a directory failed to get deleted.
- */
- public static void removeDirectory( File dir )
- throws IOException
- {
- if ( dir != null )
- {
- Log log = new SilentLog();
- FileSetManager fileSetManager = new FileSetManager( log, false );
-
- FileSet fs = new FileSet();
- fs.setDirectory( dir.getPath() );
- fs.addInclude( "**/**" );
- fileSetManager.delete( fs );
-
- }
- }
-
- public static ArtifactFactory getArtifactFactory()
- throws IllegalAccessException
- {
- ArtifactFactory artifactFactory;
- ArtifactHandlerManager manager = new DefaultArtifactHandlerManager();
- setVariableValueToObject( manager, "artifactHandlers", new HashMap() );
-
- artifactFactory = new DefaultArtifactFactory();
- setVariableValueToObject( artifactFactory, "artifactHandlerManager", manager );
-
- return artifactFactory;
- }
-
- /**
- * convience method to set values to variables in objects that don't have
- * setters
- *
- * @param object
- * @param variable
- * @param value
- * @throws IllegalAccessException
- */
- public static void setVariableValueToObject( Object object, String variable, Object value )
- throws IllegalAccessException
- {
- Field field = ReflectionUtils.getFieldByNameIncludingSuperclasses( variable, object.getClass() );
-
- field.setAccessible( true );
-
- field.set( object, value );
- }
-
- public static void setFileModifiedTime( File file )
- throws InterruptedException
- {
- Thread.sleep( 100 );
- // round down to the last second
- long time = System.currentTimeMillis();
- time = time - ( time % 1000 );
- file.setLastModified( time );
- // wait at least a second for filesystems that only record to the
- // nearest second.
- Thread.sleep( 1000 );
- }
-
-}
+package org.apache.maven.plugin.dependency.testUtils;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+import java.io.IOException;
+import java.lang.reflect.Field;
+import java.util.HashMap;
+
+import org.apache.maven.artifact.factory.ArtifactFactory;
+import org.apache.maven.artifact.factory.DefaultArtifactFactory;
+import org.apache.maven.artifact.handler.manager.ArtifactHandlerManager;
+import org.apache.maven.artifact.handler.manager.DefaultArtifactHandlerManager;
+import org.apache.maven.plugin.MojoExecutionException;
+import org.apache.maven.plugin.logging.Log;
+import org.apache.maven.plugin.testing.SilentLog;
+import org.apache.maven.shared.model.fileset.FileSet;
+import org.apache.maven.shared.model.fileset.util.FileSetManager;
+import org.codehaus.plexus.util.ReflectionUtils;
+
+public class DependencyTestUtils
+{
+
+ /**
+ * Deletes a directory and its contents.
+ *
+ * @param dir
+ * The base directory of the included and excluded files.
+ * @throws IOException
+ * @throws MojoExecutionException
+ * When a directory failed to get deleted.
+ */
+ public static void removeDirectory( File dir )
+ throws IOException
+ {
+ if ( dir != null )
+ {
+ Log log = new SilentLog();
+ FileSetManager fileSetManager = new FileSetManager( log, false );
+
+ FileSet fs = new FileSet();
+ fs.setDirectory( dir.getPath() );
+ fs.addInclude( "**/**" );
+ fileSetManager.delete( fs );
+
+ }
+ }
+
+ public static ArtifactFactory getArtifactFactory()
+ throws IllegalAccessException
+ {
+ ArtifactFactory artifactFactory;
+ ArtifactHandlerManager manager = new DefaultArtifactHandlerManager();
+ setVariableValueToObject( manager, "artifactHandlers", new HashMap() );
+
+ artifactFactory = new DefaultArtifactFactory();
+ setVariableValueToObject( artifactFactory, "artifactHandlerManager", manager );
+
+ return artifactFactory;
+ }
+
+ /**
+ * convience method to set values to variables in objects that don't have
+ * setters
+ *
+ * @param object
+ * @param variable
+ * @param value
+ * @throws IllegalAccessException
+ */
+ public static void setVariableValueToObject( Object object, String variable, Object value )
+ throws IllegalAccessException
+ {
+ Field field = ReflectionUtils.getFieldByNameIncludingSuperclasses( variable, object.getClass() );
+
+ field.setAccessible( true );
+
+ field.set( object, value );
+ }
+
+ public static void setFileModifiedTime( File file )
+ throws InterruptedException
+ {
+ Thread.sleep( 100 );
+ // round down to the last second
+ long time = System.currentTimeMillis();
+ time = time - ( time % 1000 );
+ file.setLastModified( time );
+ // wait at least a second for filesystems that only record to the
+ // nearest second.
+ Thread.sleep( 1000 );
+ }
+
+}
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyTestUtils.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyTestUtils.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Mon Jul 2 09:06:19 2007
@@ -1 +1 @@
-Author Date Id HeadURL Revision
+Author Date Id Revision
Modified: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/DependencyProjectStub.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/DependencyProjectStub.java?view=diff&rev=552524&r1=552523&r2=552524
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/DependencyProjectStub.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/DependencyProjectStub.java Mon Jul 2 09:06:19 2007
@@ -1,1045 +1,1045 @@
-package org.apache.maven.plugin.dependency.testUtils.stubs;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import java.io.File;
-import java.io.IOException;
-import java.io.Writer;
-import java.util.Collections;
-import java.util.List;
-import java.util.Map;
-import java.util.Properties;
-import java.util.Set;
-
-import org.apache.maven.artifact.Artifact;
-import org.apache.maven.artifact.DefaultArtifact;
-import org.apache.maven.artifact.DependencyResolutionRequiredException;
-import org.apache.maven.artifact.factory.ArtifactFactory;
-import org.apache.maven.artifact.handler.ArtifactHandler;
-import org.apache.maven.artifact.repository.ArtifactRepository;
-import org.apache.maven.artifact.resolver.filter.ArtifactFilter;
-import org.apache.maven.artifact.versioning.VersionRange;
-import org.apache.maven.model.Build;
-import org.apache.maven.model.CiManagement;
-import org.apache.maven.model.Contributor;
-import org.apache.maven.model.DependencyManagement;
-import org.apache.maven.model.Developer;
-import org.apache.maven.model.DistributionManagement;
-import org.apache.maven.model.IssueManagement;
-import org.apache.maven.model.License;
-import org.apache.maven.model.MailingList;
-import org.apache.maven.model.Model;
-import org.apache.maven.model.Organization;
-import org.apache.maven.model.Plugin;
-import org.apache.maven.model.PluginManagement;
-import org.apache.maven.model.Prerequisites;
-import org.apache.maven.model.Reporting;
-import org.apache.maven.model.Resource;
-import org.apache.maven.model.Scm;
-import org.apache.maven.plugin.testing.stubs.DefaultArtifactHandlerStub;
-import org.apache.maven.project.MavenProject;
-import org.apache.maven.project.artifact.InvalidDependencyVersionException;
-import org.codehaus.plexus.PlexusTestCase;
-import org.codehaus.plexus.util.xml.Xpp3Dom;
-
-/**
- * very simple stub of maven project, going to take a lot of work to make it
- * useful as a stub though
- */
-public class DependencyProjectStub
- extends MavenProject
-{
- private String groupId;
-
- private String artifactId;
-
- private String name;
-
- private Model model;
-
- private MavenProject parent;
-
- private List dependencies;
-
- private File file;
-
- private List collectedProjects;
-
- private List attachedArtifacts;
-
- private List compileSourceRoots;
-
- private List testCompileSourceRoots;
-
- private List scriptSourceRoots;
-
- private List pluginArtifactRepositories;
-
- // private ArtifactRepository releaseArtifactRepository;
-
- // private ArtifactRepository snapshotArtifactRepository;
-
- private List activeProfiles;
-
- private Set dependencyArtifacts;
-
- private DependencyManagement dependencyManagement;
-
- private Artifact artifact;
-
- // private Map artifactMap;
-
- private Model originalModel;
-
- // private Map pluginArtifactMap;
-
- // private Map reportArtifactMap;
-
- // private Map extensionArtifactMap;
-
- // private Map projectReferences;
-
- // private Build buildOverlay;
-
- private boolean executionRoot;
-
- private List compileArtifacts;
-
- private List compileDependencies;
-
- private List systemDependencies;
-
- private List testClasspathElements;
-
- private List testDependencies;
-
- private List systemClasspathElements;
-
- private List systemArtifacts;
-
- private List testArtifacts;
-
- private List runtimeArtifacts;
-
- private List runtimeDependencies;
-
- private List runtimeClasspathElements;
-
- private String modelVersion;
-
- private String packaging;
-
- private String inceptionYear;
-
- private String url;
-
- private String description;
-
- private String version;
-
- private String defaultGoal;
-
- private Set artifacts;
-
- public DependencyProjectStub()
- {
- super( (Model) null );
- }
-
- // kinda dangerous...
- public DependencyProjectStub( Model model )
- {
- // super(model);
- super( (Model) null );
- }
-
- // kinda dangerous...
- public DependencyProjectStub( MavenProject project )
- {
- // super(project);
- super( (Model) null );
- }
-
- public String getModulePathAdjustment( MavenProject mavenProject )
- throws IOException
- {
- return "";
- }
-
- public Artifact getArtifact()
- {
- if ( artifact == null )
- {
- ArtifactHandler ah = new DefaultArtifactHandlerStub( "jar", null );
-
- VersionRange vr = VersionRange.createFromVersion( "1.0" );
- Artifact art = new DefaultArtifact( "group", "artifact", vr, Artifact.SCOPE_COMPILE, "jar", null, ah, false );
- setArtifact( art );
- }
- return artifact;
- }
-
- public void setArtifact( Artifact artifact )
- {
- this.artifact = artifact;
- }
-
- public Model getModel()
- {
- return model;
- }
-
- public MavenProject getParent()
- {
- return parent;
- }
-
- public void setParent( MavenProject mavenProject )
- {
- this.parent = mavenProject;
- }
-
- public void setRemoteArtifactRepositories( List list )
- {
-
- }
-
- public List getRemoteArtifactRepositories()
- {
- return Collections.singletonList( "" );
- }
-
- public boolean hasParent()
- {
- if ( parent != null )
- {
- return true;
- }
- else
- {
- return false;
- }
- }
-
- public File getFile()
- {
- return file;
- }
-
- public void setFile( File file )
- {
- this.file = file;
- }
-
- public File getBasedir()
- {
- return new File( PlexusTestCase.getBasedir() );
- }
-
- public void setDependencies( List list )
- {
- dependencies = list;
- }
-
- public List getDependencies()
- {
- if ( dependencies == null )
- {
- dependencies = Collections.EMPTY_LIST;
- }
- return dependencies;
- }
-
- public void setDependencyManagement(DependencyManagement depMgt)
- {
- this.dependencyManagement = depMgt;
- }
- public DependencyManagement getDependencyManagement()
- {
- if ( dependencyManagement == null )
- {
- dependencyManagement = new DependencyManagement();
- }
-
- return dependencyManagement;
- }
-
- public void addCompileSourceRoot( String string )
- {
- if ( compileSourceRoots == null )
- {
- compileSourceRoots = Collections.singletonList( string );
- }
- else
- {
- compileSourceRoots.add( string );
- }
- }
-
- public void addScriptSourceRoot( String string )
- {
- if ( scriptSourceRoots == null )
- {
- scriptSourceRoots = Collections.singletonList( string );
- }
- else
- {
- scriptSourceRoots.add( string );
- }
- }
-
- public void addTestCompileSourceRoot( String string )
- {
- if ( testCompileSourceRoots == null )
- {
- testCompileSourceRoots = Collections.singletonList( string );
- }
- else
- {
- testCompileSourceRoots.add( string );
- }
- }
-
- public List getCompileSourceRoots()
- {
- return compileSourceRoots;
- }
-
- public List getScriptSourceRoots()
- {
- return scriptSourceRoots;
- }
-
- public List getTestCompileSourceRoots()
- {
- return testCompileSourceRoots;
- }
-
- public List getCompileClasspathElements()
- throws DependencyResolutionRequiredException
- {
- return compileSourceRoots;
- }
-
- public void setCompileArtifacts( List compileArtifacts )
- {
- this.compileArtifacts = compileArtifacts;
- }
-
- public List getCompileArtifacts()
- {
- return compileArtifacts;
- }
-
- public List getCompileDependencies()
- {
- return compileDependencies;
- }
-
- public List getTestClasspathElements()
- throws DependencyResolutionRequiredException
- {
- return testClasspathElements;
- }
-
- public List getTestArtifacts()
- {
- return testArtifacts;
- }
-
- public List getTestDependencies()
- {
- return testDependencies;
- }
-
- public List getRuntimeClasspathElements()
- throws DependencyResolutionRequiredException
- {
- return runtimeClasspathElements;
- }
-
- public List getRuntimeArtifacts()
- {
- return runtimeArtifacts;
- }
-
- public List getRuntimeDependencies()
- {
- return runtimeDependencies;
- }
-
- public List getSystemClasspathElements()
- throws DependencyResolutionRequiredException
- {
- return systemClasspathElements;
- }
-
- public List getSystemArtifacts()
- {
- return systemArtifacts;
- }
-
- public void setRuntimeClasspathElements( List runtimeClasspathElements )
- {
- this.runtimeClasspathElements = runtimeClasspathElements;
- }
-
- public void setAttachedArtifacts( List attachedArtifacts )
- {
- this.attachedArtifacts = attachedArtifacts;
- }
-
- public void setCompileSourceRoots( List compileSourceRoots )
- {
- this.compileSourceRoots = compileSourceRoots;
- }
-
- public void setTestCompileSourceRoots( List testCompileSourceRoots )
- {
- this.testCompileSourceRoots = testCompileSourceRoots;
- }
-
- public void setScriptSourceRoots( List scriptSourceRoots )
- {
- this.scriptSourceRoots = scriptSourceRoots;
- }
-
- public void setArtifactMap( Map artifactMap )
- {
- // this.artifactMap = artifactMap;
- }
-
- public void setPluginArtifactMap( Map pluginArtifactMap )
- {
- // this.pluginArtifactMap = pluginArtifactMap;
- }
-
- public void setReportArtifactMap( Map reportArtifactMap )
- {
- // this.reportArtifactMap = reportArtifactMap;
- }
-
- public void setExtensionArtifactMap( Map extensionArtifactMap )
- {
- // this.extensionArtifactMap = extensionArtifactMap;
- }
-
- public void setProjectReferences( Map projectReferences )
- {
- // this.projectReferences = projectReferences;
- }
-
- public void setBuildOverlay( Build buildOverlay )
- {
- // this.buildOverlay = buildOverlay;
- }
-
- public void setCompileDependencies( List compileDependencies )
- {
- this.compileDependencies = compileDependencies;
- }
-
- public void setSystemDependencies( List systemDependencies )
- {
- this.systemDependencies = systemDependencies;
- }
-
- public void setTestClasspathElements( List testClasspathElements )
- {
- this.testClasspathElements = testClasspathElements;
- }
-
- public void setTestDependencies( List testDependencies )
- {
- this.testDependencies = testDependencies;
- }
-
- public void setSystemClasspathElements( List systemClasspathElements )
- {
- this.systemClasspathElements = systemClasspathElements;
- }
-
- public void setSystemArtifacts( List systemArtifacts )
- {
- this.systemArtifacts = systemArtifacts;
- }
-
- public void setTestArtifacts( List testArtifacts )
- {
- this.testArtifacts = testArtifacts;
- }
-
- public void setRuntimeArtifacts( List runtimeArtifacts )
- {
- this.runtimeArtifacts = runtimeArtifacts;
- }
-
- public void setRuntimeDependencies( List runtimeDependencies )
- {
- this.runtimeDependencies = runtimeDependencies;
- }
-
- public void setModel( Model model )
- {
- this.model = model;
- }
-
- public List getSystemDependencies()
- {
- return systemDependencies;
- }
-
- public void setModelVersion( String string )
- {
- this.modelVersion = string;
- }
-
- public String getModelVersion()
- {
- return modelVersion;
- }
-
- public String getId()
- {
- return "";
- }
-
- public void setGroupId( String string )
- {
- this.groupId = string;
- }
-
- public String getGroupId()
- {
- return groupId;
- }
-
- public void setArtifactId( String string )
- {
- this.artifactId = string;
- }
-
- public String getArtifactId()
- {
- return artifactId;
- }
-
- public void setName( String string )
- {
- this.name = string;
- }
-
- public String getName()
- {
- return name;
- }
-
- public void setVersion( String string )
- {
- this.version = string;
- }
-
- public String getVersion()
- {
- return version;
- }
-
- public String getPackaging()
- {
- return packaging;
- }
-
- public void setPackaging( String string )
- {
- this.packaging = string;
- }
-
- public void setInceptionYear( String string )
- {
- this.inceptionYear = string;
- }
-
- public String getInceptionYear()
- {
- return inceptionYear;
- }
-
- public void setUrl( String string )
- {
- this.url = string;
- }
-
- public String getUrl()
- {
- return url;
- }
-
- public Prerequisites getPrerequisites()
- {
- return null;
- }
-
- public void setIssueManagement( IssueManagement issueManagement )
- {
-
- }
-
- public CiManagement getCiManagement()
- {
- return null;
- }
-
- public void setCiManagement( CiManagement ciManagement )
- {
-
- }
-
- public IssueManagement getIssueManagement()
- {
- return null;
- }
-
- public void setDistributionManagement( DistributionManagement distributionManagement )
- {
-
- }
-
- public DistributionManagement getDistributionManagement()
- {
- return null;
- }
-
- public void setDescription( String string )
- {
- this.description = string;
- }
-
- public String getDescription()
- {
- return description;
- }
-
- public void setOrganization( Organization organization )
- {
-
- }
-
- public Organization getOrganization()
- {
- return null;
- }
-
- public void setScm( Scm scm )
- {
-
- }
-
- public Scm getScm()
- {
- return null;
- }
-
- public void setMailingLists( List list )
- {
-
- }
-
- public List getMailingLists()
- {
- return Collections.singletonList( "" );
- }
-
- public void addMailingList( MailingList mailingList )
- {
-
- }
-
- public void setDevelopers( List list )
- {
-
- }
-
- public List getDevelopers()
- {
- return Collections.singletonList( "" );
- }
-
- public void addDeveloper( Developer developer )
- {
-
- }
-
- public void setContributors( List list )
- {
-
- }
-
- public List getContributors()
- {
- return Collections.singletonList( "" );
- }
-
- public void addContributor( Contributor contributor )
- {
-
- }
-
- public void setBuild( Build build )
- {
-
- }
-
- public Build getBuild()
- {
- return null;
- }
-
- public List getResources()
- {
- return Collections.singletonList( "" );
- }
-
- public List getTestResources()
- {
- return Collections.singletonList( "" );
- }
-
- public void addResource( Resource resource )
- {
-
- }
-
- public void addTestResource( Resource resource )
- {
-
- }
-
- public void setReporting( Reporting reporting )
- {
-
- }
-
- public Reporting getReporting()
- {
- return null;
- }
-
- public void setLicenses( List list )
- {
-
- }
-
- public List getLicenses()
- {
- return Collections.singletonList( "" );
- }
-
- public void addLicense( License license )
- {
-
- }
-
- public void setArtifacts( Set set )
- {
- this.artifacts = set;
- }
-
- public Set getArtifacts()
- {
- if ( artifacts == null )
- {
- return Collections.EMPTY_SET;
- }
- else
- {
- return artifacts;
- }
- }
-
- public Map getArtifactMap()
- {
- return Collections.singletonMap( "", "" );
- }
-
- public void setPluginArtifacts( Set set )
- {
-
- }
-
- public Set getPluginArtifacts()
- {
- return Collections.singleton( "" );
- }
-
- public Map getPluginArtifactMap()
- {
- return Collections.singletonMap( "", "" );
- }
-
- public void setReportArtifacts( Set set )
- {
-
- }
-
- public Set getReportArtifacts()
- {
- return Collections.singleton( "" );
- }
-
- public Map getReportArtifactMap()
- {
- return Collections.singletonMap( "", "" );
- }
-
- public void setExtensionArtifacts( Set set )
- {
-
- }
-
- public Set getExtensionArtifacts()
- {
- return Collections.singleton( "" );
- }
-
- public Map getExtensionArtifactMap()
- {
- return Collections.singletonMap( "", "" );
- }
-
- public void setParentArtifact( Artifact artifact )
- {
-
- }
-
- public Artifact getParentArtifact()
- {
- return null;
- }
-
- public List getRepositories()
- {
- return Collections.singletonList( "" );
- }
-
- public List getReportPlugins()
- {
- return Collections.singletonList( "" );
- }
-
- public List getBuildPlugins()
- {
- return Collections.singletonList( "" );
- }
-
- public List getModules()
- {
- return Collections.singletonList( "" );
- }
-
- public PluginManagement getPluginManagement()
- {
- return null;
- }
-
- public void addPlugin( Plugin plugin )
- {
-
- }
-
- public void injectPluginManagementInfo( Plugin plugin )
- {
-
- }
-
- public List getCollectedProjects()
- {
- return collectedProjects;
- }
-
- public void setCollectedProjects( List list )
- {
- this.collectedProjects = list;
- }
-
- public void setPluginArtifactRepositories( List list )
- {
- this.pluginArtifactRepositories = list;
- }
-
- public List getPluginArtifactRepositories()
- {
- return pluginArtifactRepositories;
- }
-
- public ArtifactRepository getDistributionManagementArtifactRepository()
- {
- return null;
- }
-
- public List getPluginRepositories()
- {
- return Collections.singletonList( "" );
- }
-
- public void setActiveProfiles( List list )
- {
- activeProfiles = list;
- }
-
- public List getActiveProfiles()
- {
- return activeProfiles;
- }
-
- public void addAttachedArtifact( Artifact theArtifact )
- {
- if ( attachedArtifacts == null )
- {
- this.attachedArtifacts = Collections.singletonList( theArtifact );
- }
- else
- {
- attachedArtifacts.add( theArtifact );
- }
- }
-
- public List getAttachedArtifacts()
- {
- return attachedArtifacts;
- }
-
- public Xpp3Dom getGoalConfiguration( String string, String string1, String string2, String string3 )
- {
- return null;
- }
-
- public Xpp3Dom getReportConfiguration( String string, String string1, String string2 )
- {
- return null;
- }
-
- public MavenProject getExecutionProject()
- {
- return null;
- }
-
- public void setExecutionProject( MavenProject mavenProject )
- {
-
- }
-
- public void writeModel( Writer writer )
- throws IOException
- {
-
- }
-
- public void writeOriginalModel( Writer writer )
- throws IOException
- {
-
- }
-
- public Set getDependencyArtifacts()
- {
- return dependencyArtifacts;
- }
-
- public void setDependencyArtifacts( Set set )
- {
- this.dependencyArtifacts = set;
- }
-
- public void setReleaseArtifactRepository( ArtifactRepository artifactRepository )
- {
- // this.releaseArtifactRepository = artifactRepository;
- }
-
- public void setSnapshotArtifactRepository( ArtifactRepository artifactRepository )
- {
- // this.snapshotArtifactRepository = artifactRepository;
- }
-
- public void setOriginalModel( Model model )
- {
- this.originalModel = model;
- }
-
- public Model getOriginalModel()
- {
- return originalModel;
- }
-
- public List getBuildExtensions()
- {
- return Collections.singletonList( "" );
- }
-
- public Set createArtifacts( ArtifactFactory artifactFactory, String string, ArtifactFilter artifactFilter )
- throws InvalidDependencyVersionException
- {
- return Collections.EMPTY_SET;
- }
-
- public void addProjectReference( MavenProject mavenProject )
- {
-
- }
-
- public void attachArtifact( String string, String string1, File theFile )
- {
-
- }
-
- public Properties getProperties()
- {
- return new Properties();
- }
-
- public List getFilters()
- {
- return Collections.singletonList( "" );
- }
-
- public Map getProjectReferences()
- {
- return Collections.singletonMap( "", "" );
- }
-
- public boolean isExecutionRoot()
- {
- return executionRoot;
- }
-
- public void setExecutionRoot( boolean b )
- {
- this.executionRoot = b;
- }
-
- public String getDefaultGoal()
- {
- return defaultGoal;
- }
-
- public Artifact replaceWithActiveArtifact( Artifact theArtifact )
- {
- return null;
- }
-}
+package org.apache.maven.plugin.dependency.testUtils.stubs;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+import java.io.IOException;
+import java.io.Writer;
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+import java.util.Set;
+
+import org.apache.maven.artifact.Artifact;
+import org.apache.maven.artifact.DefaultArtifact;
+import org.apache.maven.artifact.DependencyResolutionRequiredException;
+import org.apache.maven.artifact.factory.ArtifactFactory;
+import org.apache.maven.artifact.handler.ArtifactHandler;
+import org.apache.maven.artifact.repository.ArtifactRepository;
+import org.apache.maven.artifact.resolver.filter.ArtifactFilter;
+import org.apache.maven.artifact.versioning.VersionRange;
+import org.apache.maven.model.Build;
+import org.apache.maven.model.CiManagement;
+import org.apache.maven.model.Contributor;
+import org.apache.maven.model.DependencyManagement;
+import org.apache.maven.model.Developer;
+import org.apache.maven.model.DistributionManagement;
+import org.apache.maven.model.IssueManagement;
+import org.apache.maven.model.License;
+import org.apache.maven.model.MailingList;
+import org.apache.maven.model.Model;
+import org.apache.maven.model.Organization;
+import org.apache.maven.model.Plugin;
+import org.apache.maven.model.PluginManagement;
+import org.apache.maven.model.Prerequisites;
+import org.apache.maven.model.Reporting;
+import org.apache.maven.model.Resource;
+import org.apache.maven.model.Scm;
+import org.apache.maven.plugin.testing.stubs.DefaultArtifactHandlerStub;
+import org.apache.maven.project.MavenProject;
+import org.apache.maven.project.artifact.InvalidDependencyVersionException;
+import org.codehaus.plexus.PlexusTestCase;
+import org.codehaus.plexus.util.xml.Xpp3Dom;
+
+/**
+ * very simple stub of maven project, going to take a lot of work to make it
+ * useful as a stub though
+ */
+public class DependencyProjectStub
+ extends MavenProject
+{
+ private String groupId;
+
+ private String artifactId;
+
+ private String name;
+
+ private Model model;
+
+ private MavenProject parent;
+
+ private List dependencies;
+
+ private File file;
+
+ private List collectedProjects;
+
+ private List attachedArtifacts;
+
+ private List compileSourceRoots;
+
+ private List testCompileSourceRoots;
+
+ private List scriptSourceRoots;
+
+ private List pluginArtifactRepositories;
+
+ // private ArtifactRepository releaseArtifactRepository;
+
+ // private ArtifactRepository snapshotArtifactRepository;
+
+ private List activeProfiles;
+
+ private Set dependencyArtifacts;
+
+ private DependencyManagement dependencyManagement;
+
+ private Artifact artifact;
+
+ // private Map artifactMap;
+
+ private Model originalModel;
+
+ // private Map pluginArtifactMap;
+
+ // private Map reportArtifactMap;
+
+ // private Map extensionArtifactMap;
+
+ // private Map projectReferences;
+
+ // private Build buildOverlay;
+
+ private boolean executionRoot;
+
+ private List compileArtifacts;
+
+ private List compileDependencies;
+
+ private List systemDependencies;
+
+ private List testClasspathElements;
+
+ private List testDependencies;
+
+ private List systemClasspathElements;
+
+ private List systemArtifacts;
+
+ private List testArtifacts;
+
+ private List runtimeArtifacts;
+
+ private List runtimeDependencies;
+
+ private List runtimeClasspathElements;
+
+ private String modelVersion;
+
+ private String packaging;
+
+ private String inceptionYear;
+
+ private String url;
+
+ private String description;
+
+ private String version;
+
+ private String defaultGoal;
+
+ private Set artifacts;
+
+ public DependencyProjectStub()
+ {
+ super( (Model) null );
+ }
+
+ // kinda dangerous...
+ public DependencyProjectStub( Model model )
+ {
+ // super(model);
+ super( (Model) null );
+ }
+
+ // kinda dangerous...
+ public DependencyProjectStub( MavenProject project )
+ {
+ // super(project);
+ super( (Model) null );
+ }
+
+ public String getModulePathAdjustment( MavenProject mavenProject )
+ throws IOException
+ {
+ return "";
+ }
+
+ public Artifact getArtifact()
+ {
+ if ( artifact == null )
+ {
+ ArtifactHandler ah = new DefaultArtifactHandlerStub( "jar", null );
+
+ VersionRange vr = VersionRange.createFromVersion( "1.0" );
+ Artifact art = new DefaultArtifact( "group", "artifact", vr, Artifact.SCOPE_COMPILE, "jar", null, ah, false );
+ setArtifact( art );
+ }
+ return artifact;
+ }
+
+ public void setArtifact( Artifact artifact )
+ {
+ this.artifact = artifact;
+ }
+
+ public Model getModel()
+ {
+ return model;
+ }
+
+ public MavenProject getParent()
+ {
+ return parent;
+ }
+
+ public void setParent( MavenProject mavenProject )
+ {
+ this.parent = mavenProject;
+ }
+
+ public void setRemoteArtifactRepositories( List list )
+ {
+
+ }
+
+ public List getRemoteArtifactRepositories()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public boolean hasParent()
+ {
+ if ( parent != null )
+ {
+ return true;
+ }
+ else
+ {
+ return false;
+ }
+ }
+
+ public File getFile()
+ {
+ return file;
+ }
+
+ public void setFile( File file )
+ {
+ this.file = file;
+ }
+
+ public File getBasedir()
+ {
+ return new File( PlexusTestCase.getBasedir() );
+ }
+
+ public void setDependencies( List list )
+ {
+ dependencies = list;
+ }
+
+ public List getDependencies()
+ {
+ if ( dependencies == null )
+ {
+ dependencies = Collections.EMPTY_LIST;
+ }
+ return dependencies;
+ }
+
+ public void setDependencyManagement(DependencyManagement depMgt)
+ {
+ this.dependencyManagement = depMgt;
+ }
+ public DependencyManagement getDependencyManagement()
+ {
+ if ( dependencyManagement == null )
+ {
+ dependencyManagement = new DependencyManagement();
+ }
+
+ return dependencyManagement;
+ }
+
+ public void addCompileSourceRoot( String string )
+ {
+ if ( compileSourceRoots == null )
+ {
+ compileSourceRoots = Collections.singletonList( string );
+ }
+ else
+ {
+ compileSourceRoots.add( string );
+ }
+ }
+
+ public void addScriptSourceRoot( String string )
+ {
+ if ( scriptSourceRoots == null )
+ {
+ scriptSourceRoots = Collections.singletonList( string );
+ }
+ else
+ {
+ scriptSourceRoots.add( string );
+ }
+ }
+
+ public void addTestCompileSourceRoot( String string )
+ {
+ if ( testCompileSourceRoots == null )
+ {
+ testCompileSourceRoots = Collections.singletonList( string );
+ }
+ else
+ {
+ testCompileSourceRoots.add( string );
+ }
+ }
+
+ public List getCompileSourceRoots()
+ {
+ return compileSourceRoots;
+ }
+
+ public List getScriptSourceRoots()
+ {
+ return scriptSourceRoots;
+ }
+
+ public List getTestCompileSourceRoots()
+ {
+ return testCompileSourceRoots;
+ }
+
+ public List getCompileClasspathElements()
+ throws DependencyResolutionRequiredException
+ {
+ return compileSourceRoots;
+ }
+
+ public void setCompileArtifacts( List compileArtifacts )
+ {
+ this.compileArtifacts = compileArtifacts;
+ }
+
+ public List getCompileArtifacts()
+ {
+ return compileArtifacts;
+ }
+
+ public List getCompileDependencies()
+ {
+ return compileDependencies;
+ }
+
+ public List getTestClasspathElements()
+ throws DependencyResolutionRequiredException
+ {
+ return testClasspathElements;
+ }
+
+ public List getTestArtifacts()
+ {
+ return testArtifacts;
+ }
+
+ public List getTestDependencies()
+ {
+ return testDependencies;
+ }
+
+ public List getRuntimeClasspathElements()
+ throws DependencyResolutionRequiredException
+ {
+ return runtimeClasspathElements;
+ }
+
+ public List getRuntimeArtifacts()
+ {
+ return runtimeArtifacts;
+ }
+
+ public List getRuntimeDependencies()
+ {
+ return runtimeDependencies;
+ }
+
+ public List getSystemClasspathElements()
+ throws DependencyResolutionRequiredException
+ {
+ return systemClasspathElements;
+ }
+
+ public List getSystemArtifacts()
+ {
+ return systemArtifacts;
+ }
+
+ public void setRuntimeClasspathElements( List runtimeClasspathElements )
+ {
+ this.runtimeClasspathElements = runtimeClasspathElements;
+ }
+
+ public void setAttachedArtifacts( List attachedArtifacts )
+ {
+ this.attachedArtifacts = attachedArtifacts;
+ }
+
+ public void setCompileSourceRoots( List compileSourceRoots )
+ {
+ this.compileSourceRoots = compileSourceRoots;
+ }
+
+ public void setTestCompileSourceRoots( List testCompileSourceRoots )
+ {
+ this.testCompileSourceRoots = testCompileSourceRoots;
+ }
+
+ public void setScriptSourceRoots( List scriptSourceRoots )
+ {
+ this.scriptSourceRoots = scriptSourceRoots;
+ }
+
+ public void setArtifactMap( Map artifactMap )
+ {
+ // this.artifactMap = artifactMap;
+ }
+
+ public void setPluginArtifactMap( Map pluginArtifactMap )
+ {
+ // this.pluginArtifactMap = pluginArtifactMap;
+ }
+
+ public void setReportArtifactMap( Map reportArtifactMap )
+ {
+ // this.reportArtifactMap = reportArtifactMap;
+ }
+
+ public void setExtensionArtifactMap( Map extensionArtifactMap )
+ {
+ // this.extensionArtifactMap = extensionArtifactMap;
+ }
+
+ public void setProjectReferences( Map projectReferences )
+ {
+ // this.projectReferences = projectReferences;
+ }
+
+ public void setBuildOverlay( Build buildOverlay )
+ {
+ // this.buildOverlay = buildOverlay;
+ }
+
+ public void setCompileDependencies( List compileDependencies )
+ {
+ this.compileDependencies = compileDependencies;
+ }
+
+ public void setSystemDependencies( List systemDependencies )
+ {
+ this.systemDependencies = systemDependencies;
+ }
+
+ public void setTestClasspathElements( List testClasspathElements )
+ {
+ this.testClasspathElements = testClasspathElements;
+ }
+
+ public void setTestDependencies( List testDependencies )
+ {
+ this.testDependencies = testDependencies;
+ }
+
+ public void setSystemClasspathElements( List systemClasspathElements )
+ {
+ this.systemClasspathElements = systemClasspathElements;
+ }
+
+ public void setSystemArtifacts( List systemArtifacts )
+ {
+ this.systemArtifacts = systemArtifacts;
+ }
+
+ public void setTestArtifacts( List testArtifacts )
+ {
+ this.testArtifacts = testArtifacts;
+ }
+
+ public void setRuntimeArtifacts( List runtimeArtifacts )
+ {
+ this.runtimeArtifacts = runtimeArtifacts;
+ }
+
+ public void setRuntimeDependencies( List runtimeDependencies )
+ {
+ this.runtimeDependencies = runtimeDependencies;
+ }
+
+ public void setModel( Model model )
+ {
+ this.model = model;
+ }
+
+ public List getSystemDependencies()
+ {
+ return systemDependencies;
+ }
+
+ public void setModelVersion( String string )
+ {
+ this.modelVersion = string;
+ }
+
+ public String getModelVersion()
+ {
+ return modelVersion;
+ }
+
+ public String getId()
+ {
+ return "";
+ }
+
+ public void setGroupId( String string )
+ {
+ this.groupId = string;
+ }
+
+ public String getGroupId()
+ {
+ return groupId;
+ }
+
+ public void setArtifactId( String string )
+ {
+ this.artifactId = string;
+ }
+
+ public String getArtifactId()
+ {
+ return artifactId;
+ }
+
+ public void setName( String string )
+ {
+ this.name = string;
+ }
+
+ public String getName()
+ {
+ return name;
+ }
+
+ public void setVersion( String string )
+ {
+ this.version = string;
+ }
+
+ public String getVersion()
+ {
+ return version;
+ }
+
+ public String getPackaging()
+ {
+ return packaging;
+ }
+
+ public void setPackaging( String string )
+ {
+ this.packaging = string;
+ }
+
+ public void setInceptionYear( String string )
+ {
+ this.inceptionYear = string;
+ }
+
+ public String getInceptionYear()
+ {
+ return inceptionYear;
+ }
+
+ public void setUrl( String string )
+ {
+ this.url = string;
+ }
+
+ public String getUrl()
+ {
+ return url;
+ }
+
+ public Prerequisites getPrerequisites()
+ {
+ return null;
+ }
+
+ public void setIssueManagement( IssueManagement issueManagement )
+ {
+
+ }
+
+ public CiManagement getCiManagement()
+ {
+ return null;
+ }
+
+ public void setCiManagement( CiManagement ciManagement )
+ {
+
+ }
+
+ public IssueManagement getIssueManagement()
+ {
+ return null;
+ }
+
+ public void setDistributionManagement( DistributionManagement distributionManagement )
+ {
+
+ }
+
+ public DistributionManagement getDistributionManagement()
+ {
+ return null;
+ }
+
+ public void setDescription( String string )
+ {
+ this.description = string;
+ }
+
+ public String getDescription()
+ {
+ return description;
+ }
+
+ public void setOrganization( Organization organization )
+ {
+
+ }
+
+ public Organization getOrganization()
+ {
+ return null;
+ }
+
+ public void setScm( Scm scm )
+ {
+
+ }
+
+ public Scm getScm()
+ {
+ return null;
+ }
+
+ public void setMailingLists( List list )
+ {
+
+ }
+
+ public List getMailingLists()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public void addMailingList( MailingList mailingList )
+ {
+
+ }
+
+ public void setDevelopers( List list )
+ {
+
+ }
+
+ public List getDevelopers()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public void addDeveloper( Developer developer )
+ {
+
+ }
+
+ public void setContributors( List list )
+ {
+
+ }
+
+ public List getContributors()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public void addContributor( Contributor contributor )
+ {
+
+ }
+
+ public void setBuild( Build build )
+ {
+
+ }
+
+ public Build getBuild()
+ {
+ return null;
+ }
+
+ public List getResources()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public List getTestResources()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public void addResource( Resource resource )
+ {
+
+ }
+
+ public void addTestResource( Resource resource )
+ {
+
+ }
+
+ public void setReporting( Reporting reporting )
+ {
+
+ }
+
+ public Reporting getReporting()
+ {
+ return null;
+ }
+
+ public void setLicenses( List list )
+ {
+
+ }
+
+ public List getLicenses()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public void addLicense( License license )
+ {
+
+ }
+
+ public void setArtifacts( Set set )
+ {
+ this.artifacts = set;
+ }
+
+ public Set getArtifacts()
+ {
+ if ( artifacts == null )
+ {
+ return Collections.EMPTY_SET;
+ }
+ else
+ {
+ return artifacts;
+ }
+ }
+
+ public Map getArtifactMap()
+ {
+ return Collections.singletonMap( "", "" );
+ }
+
+ public void setPluginArtifacts( Set set )
+ {
+
+ }
+
+ public Set getPluginArtifacts()
+ {
+ return Collections.singleton( "" );
+ }
+
+ public Map getPluginArtifactMap()
+ {
+ return Collections.singletonMap( "", "" );
+ }
+
+ public void setReportArtifacts( Set set )
+ {
+
+ }
+
+ public Set getReportArtifacts()
+ {
+ return Collections.singleton( "" );
+ }
+
+ public Map getReportArtifactMap()
+ {
+ return Collections.singletonMap( "", "" );
+ }
+
+ public void setExtensionArtifacts( Set set )
+ {
+
+ }
+
+ public Set getExtensionArtifacts()
+ {
+ return Collections.singleton( "" );
+ }
+
+ public Map getExtensionArtifactMap()
+ {
+ return Collections.singletonMap( "", "" );
+ }
+
+ public void setParentArtifact( Artifact artifact )
+ {
+
+ }
+
+ public Artifact getParentArtifact()
+ {
+ return null;
+ }
+
+ public List getRepositories()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public List getReportPlugins()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public List getBuildPlugins()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public List getModules()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public PluginManagement getPluginManagement()
+ {
+ return null;
+ }
+
+ public void addPlugin( Plugin plugin )
+ {
+
+ }
+
+ public void injectPluginManagementInfo( Plugin plugin )
+ {
+
+ }
+
+ public List getCollectedProjects()
+ {
+ return collectedProjects;
+ }
+
+ public void setCollectedProjects( List list )
+ {
+ this.collectedProjects = list;
+ }
+
+ public void setPluginArtifactRepositories( List list )
+ {
+ this.pluginArtifactRepositories = list;
+ }
+
+ public List getPluginArtifactRepositories()
+ {
+ return pluginArtifactRepositories;
+ }
+
+ public ArtifactRepository getDistributionManagementArtifactRepository()
+ {
+ return null;
+ }
+
+ public List getPluginRepositories()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public void setActiveProfiles( List list )
+ {
+ activeProfiles = list;
+ }
+
+ public List getActiveProfiles()
+ {
+ return activeProfiles;
+ }
+
+ public void addAttachedArtifact( Artifact theArtifact )
+ {
+ if ( attachedArtifacts == null )
+ {
+ this.attachedArtifacts = Collections.singletonList( theArtifact );
+ }
+ else
+ {
+ attachedArtifacts.add( theArtifact );
+ }
+ }
+
+ public List getAttachedArtifacts()
+ {
+ return attachedArtifacts;
+ }
+
+ public Xpp3Dom getGoalConfiguration( String string, String string1, String string2, String string3 )
+ {
+ return null;
+ }
+
+ public Xpp3Dom getReportConfiguration( String string, String string1, String string2 )
+ {
+ return null;
+ }
+
+ public MavenProject getExecutionProject()
+ {
+ return null;
+ }
+
+ public void setExecutionProject( MavenProject mavenProject )
+ {
+
+ }
+
+ public void writeModel( Writer writer )
+ throws IOException
+ {
+
+ }
+
+ public void writeOriginalModel( Writer writer )
+ throws IOException
+ {
+
+ }
+
+ public Set getDependencyArtifacts()
+ {
+ return dependencyArtifacts;
+ }
+
+ public void setDependencyArtifacts( Set set )
+ {
+ this.dependencyArtifacts = set;
+ }
+
+ public void setReleaseArtifactRepository( ArtifactRepository artifactRepository )
+ {
+ // this.releaseArtifactRepository = artifactRepository;
+ }
+
+ public void setSnapshotArtifactRepository( ArtifactRepository artifactRepository )
+ {
+ // this.snapshotArtifactRepository = artifactRepository;
+ }
+
+ public void setOriginalModel( Model model )
+ {
+ this.originalModel = model;
+ }
+
+ public Model getOriginalModel()
+ {
+ return originalModel;
+ }
+
+ public List getBuildExtensions()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public Set createArtifacts( ArtifactFactory artifactFactory, String string, ArtifactFilter artifactFilter )
+ throws InvalidDependencyVersionException
+ {
+ return Collections.EMPTY_SET;
+ }
+
+ public void addProjectReference( MavenProject mavenProject )
+ {
+
+ }
+
+ public void attachArtifact( String string, String string1, File theFile )
+ {
+
+ }
+
+ public Properties getProperties()
+ {
+ return new Properties();
+ }
+
+ public List getFilters()
+ {
+ return Collections.singletonList( "" );
+ }
+
+ public Map getProjectReferences()
+ {
+ return Collections.singletonMap( "", "" );
+ }
+
+ public boolean isExecutionRoot()
+ {
+ return executionRoot;
+ }
+
+ public void setExecutionRoot( boolean b )
+ {
+ this.executionRoot = b;
+ }
+
+ public String getDefaultGoal()
+ {
+ return defaultGoal;
+ }
+
+ public Artifact replaceWithActiveArtifact( Artifact theArtifact )
+ {
+ return null;
+ }
+}
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/DependencyProjectStub.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/DependencyProjectStub.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Mon Jul 2 09:06:19 2007
@@ -1 +1 @@
-Author Date Id HeadURL Revision
+Author Date Id Revision
Modified: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubDefaultFileMarkerHandler.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubDefaultFileMarkerHandler.java?view=diff&rev=552524&r1=552523&r2=552524
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubDefaultFileMarkerHandler.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubDefaultFileMarkerHandler.java Mon Jul 2 09:06:19 2007
@@ -1,41 +1,41 @@
-package org.apache.maven.plugin.dependency.testUtils.stubs;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import java.io.File;
-
-import org.apache.maven.artifact.Artifact;
-import org.apache.maven.plugin.dependency.utils.markers.DefaultFileMarkerHandler;
-
-public class StubDefaultFileMarkerHandler
- extends DefaultFileMarkerHandler
-{
-
- public StubDefaultFileMarkerHandler( Artifact artifact, File markerFilesDirectory )
- {
- super( artifact, markerFilesDirectory );
- // TODO Auto-generated constructor stub
- }
-
- protected File getMarkerFile()
- {
- return new StubMarkerFile( this.markerFilesDirectory, this.artifact.getId().replace( ':', '-' ) + ".marker" );
- }
-}
+package org.apache.maven.plugin.dependency.testUtils.stubs;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+
+import org.apache.maven.artifact.Artifact;
+import org.apache.maven.plugin.dependency.utils.markers.DefaultFileMarkerHandler;
+
+public class StubDefaultFileMarkerHandler
+ extends DefaultFileMarkerHandler
+{
+
+ public StubDefaultFileMarkerHandler( Artifact artifact, File markerFilesDirectory )
+ {
+ super( artifact, markerFilesDirectory );
+ // TODO Auto-generated constructor stub
+ }
+
+ protected File getMarkerFile()
+ {
+ return new StubMarkerFile( this.markerFilesDirectory, this.artifact.getId().replace( ':', '-' ) + ".marker" );
+ }
+}
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubDefaultFileMarkerHandler.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubDefaultFileMarkerHandler.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Mon Jul 2 09:06:19 2007
@@ -1 +1 @@
-Author Date Id HeadURL Revision
+Author Date Id Revision
Modified: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubMarkerFile.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubMarkerFile.java?view=diff&rev=552524&r1=552523&r2=552524
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubMarkerFile.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubMarkerFile.java Mon Jul 2 09:06:19 2007
@@ -1,64 +1,64 @@
-package org.apache.maven.plugin.dependency.testUtils.stubs;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import java.io.File;
-import java.io.IOException;
-import java.net.URI;
-
-public class StubMarkerFile
- extends File
-{
-
- /**
- *
- */
- private static final long serialVersionUID = 1L;
-
- public StubMarkerFile( String pathname )
- {
- super( pathname );
- // TODO Auto-generated constructor stub
- }
-
- public StubMarkerFile( URI uri )
- {
- super( uri );
- // TODO Auto-generated constructor stub
- }
-
- public StubMarkerFile( File parent, String child )
- {
- super( parent, child );
- // TODO Auto-generated constructor stub
- }
-
- public StubMarkerFile( String parent, String child )
- {
- super( parent, child );
- // TODO Auto-generated constructor stub
- }
-
- public boolean createNewFile()
- throws IOException
- {
- throw new IOException( "Intended Error" );
- }
-}
+package org.apache.maven.plugin.dependency.testUtils.stubs;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URI;
+
+public class StubMarkerFile
+ extends File
+{
+
+ /**
+ *
+ */
+ private static final long serialVersionUID = 1L;
+
+ public StubMarkerFile( String pathname )
+ {
+ super( pathname );
+ // TODO Auto-generated constructor stub
+ }
+
+ public StubMarkerFile( URI uri )
+ {
+ super( uri );
+ // TODO Auto-generated constructor stub
+ }
+
+ public StubMarkerFile( File parent, String child )
+ {
+ super( parent, child );
+ // TODO Auto-generated constructor stub
+ }
+
+ public StubMarkerFile( String parent, String child )
+ {
+ super( parent, child );
+ // TODO Auto-generated constructor stub
+ }
+
+ public boolean createNewFile()
+ throws IOException
+ {
+ throw new IOException( "Intended Error" );
+ }
+}
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubMarkerFile.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubMarkerFile.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Mon Jul 2 09:06:19 2007
@@ -1 +1 @@
-Author Date Id HeadURL Revision
+Author Date Id Revision
Modified: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubSourcesFileMarkerHandler.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubSourcesFileMarkerHandler.java?view=diff&rev=552524&r1=552523&r2=552524
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubSourcesFileMarkerHandler.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubSourcesFileMarkerHandler.java Mon Jul 2 09:06:19 2007
@@ -1,52 +1,52 @@
-package org.apache.maven.plugin.dependency.testUtils.stubs;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import java.io.File;
-
-import org.apache.maven.artifact.Artifact;
-import org.apache.maven.plugin.dependency.utils.markers.SourcesFileMarkerHandler;
-
-public class StubSourcesFileMarkerHandler
- extends SourcesFileMarkerHandler
-{
-
- public StubSourcesFileMarkerHandler( Artifact artifact, File markerFilesDirectory, boolean resolved )
- {
- super( artifact, markerFilesDirectory, resolved );
- // TODO Auto-generated constructor stub
- }
-
- protected File getMarkerFile( boolean res )
- {
- String suffix;
- if ( res )
- {
- suffix = ".resolved";
- }
- else
- {
- suffix = ".unresolved";
- }
-
- return new StubMarkerFile( this.markerFilesDirectory, this.artifact.getId().replace( ':', '-' ) + suffix );
- }
-
-}
+package org.apache.maven.plugin.dependency.testUtils.stubs;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+
+import org.apache.maven.artifact.Artifact;
+import org.apache.maven.plugin.dependency.utils.markers.SourcesFileMarkerHandler;
+
+public class StubSourcesFileMarkerHandler
+ extends SourcesFileMarkerHandler
+{
+
+ public StubSourcesFileMarkerHandler( Artifact artifact, File markerFilesDirectory, boolean resolved )
+ {
+ super( artifact, markerFilesDirectory, resolved );
+ // TODO Auto-generated constructor stub
+ }
+
+ protected File getMarkerFile( boolean res )
+ {
+ String suffix;
+ if ( res )
+ {
+ suffix = ".resolved";
+ }
+ else
+ {
+ suffix = ".unresolved";
+ }
+
+ return new StubMarkerFile( this.markerFilesDirectory, this.artifact.getId().replace( ':', '-' ) + suffix );
+ }
+
+}
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubSourcesFileMarkerHandler.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubSourcesFileMarkerHandler.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Mon Jul 2 09:06:19 2007
@@ -1 +1 @@
-Author Date Id HeadURL Revision
+Author Date Id Revision