Modified: 
maven/archiva/trunk/archiva-reports-standard/src/test/java/org/apache/maven/archiva/reporting/LocationArtifactReportProcessorTest.java
URL: 
http://svn.apache.org/viewvc/maven/archiva/trunk/archiva-reports-standard/src/test/java/org/apache/maven/archiva/reporting/LocationArtifactReportProcessorTest.java?view=diff&rev=441377&r1=441376&r2=441377
==============================================================================
--- 
maven/archiva/trunk/archiva-reports-standard/src/test/java/org/apache/maven/archiva/reporting/LocationArtifactReportProcessorTest.java
 (original)
+++ 
maven/archiva/trunk/archiva-reports-standard/src/test/java/org/apache/maven/archiva/reporting/LocationArtifactReportProcessorTest.java
 Thu Sep  7 22:16:51 2006
@@ -17,10 +17,6 @@
  */
 
 import org.apache.maven.artifact.Artifact;
-import org.apache.maven.artifact.DefaultArtifact;
-import org.apache.maven.artifact.handler.ArtifactHandler;
-import org.apache.maven.artifact.handler.DefaultArtifactHandler;
-import org.apache.maven.artifact.versioning.VersionRange;
 import org.apache.maven.model.Model;
 import org.apache.maven.model.io.xpp3.MavenXpp3Reader;
 import org.codehaus.plexus.util.xml.pull.XmlPullParserException;
@@ -38,7 +34,7 @@
 {
     private ArtifactReportProcessor artifactReportProcessor;
 
-    private ArtifactReporter reporter = new DefaultArtifactReporter();
+    private ReportingDatabase reporter = new ReportingDatabase();
 
     private MavenXpp3Reader pomReader;
 
@@ -63,18 +59,13 @@
      * both in the file system pom and in the pom included in the package.
      */
     public void testPackagedPomLocationArtifactReporterSuccess()
-        throws ReportProcessorException, IOException, XmlPullParserException
+        throws IOException, XmlPullParserException
     {
-        ArtifactHandler handler = new DefaultArtifactHandler( "jar" );
-        VersionRange version = VersionRange.createFromVersion( "2.0" );
-        Artifact artifact =
-            new DefaultArtifact( "org.apache.maven", "maven-model", version, 
"compile", "jar", "", handler );
-
-        String path = "org/apache/maven/maven-model/2.0/maven-model-2.0.pom";
-        Model model = readPom( path );
+        Artifact artifact = createArtifact( "org.apache.maven", "maven-model", 
"2.0" );
 
-        artifactReportProcessor.processArtifact( model, artifact, reporter, 
repository );
-        assertEquals( 1, reporter.getNumSuccesses() );
+        artifactReportProcessor.processArtifact( artifact, null, reporter );
+        assertEquals( 0, reporter.getNumFailures() );
+        assertEquals( 0, reporter.getNumWarnings() );
     }
 
     /**
@@ -82,17 +73,13 @@
      * file system pom (but the jar file does not have a pom included in its 
package).
      */
     public void testLocationArtifactReporterSuccess()
-        throws ReportProcessorException, IOException, XmlPullParserException
+        throws IOException, XmlPullParserException
     {
-        ArtifactHandler handler = new DefaultArtifactHandler( "jar" );
-        VersionRange version = VersionRange.createFromVersion( "1.0-alpha-1" );
-        Artifact artifact = new DefaultArtifact( "groupId", "artifactId", 
version, "compile", "jar", "", handler );
-
-        String path = 
"groupId/artifactId/1.0-alpha-1/artifactId-1.0-alpha-1.pom";
-        Model model = readPom( path );
+        Artifact artifact = createArtifact( "groupId", "artifactId", 
"1.0-alpha-1" );
 
-        artifactReportProcessor.processArtifact( model, artifact, reporter, 
repository );
-        assertEquals( 1, reporter.getNumSuccesses() );
+        artifactReportProcessor.processArtifact( artifact, null, reporter );
+        assertEquals( 0, reporter.getNumFailures() );
+        assertEquals( 0, reporter.getNumWarnings() );
     }
 
     /**
@@ -100,16 +87,11 @@
      * in the file system pom.
      */
     public void testLocationArtifactReporterFailure()
-        throws IOException, XmlPullParserException, ReportProcessorException
+        throws IOException, XmlPullParserException
     {
-        ArtifactHandler handler = new DefaultArtifactHandler( "jar" );
-        VersionRange version = VersionRange.createFromVersion( "1.0-alpha-2" );
-        Artifact artifact = new DefaultArtifact( "groupId", "artifactId", 
version, "compile", "jar", "", handler );
-
-        String path = 
"groupId/artifactId/1.0-alpha-2/artifactId-1.0-alpha-2.pom";
-        Model model = readPom( path );
+        Artifact artifact = createArtifact( "groupId", "artifactId", 
"1.0-alpha-2" );
 
-        artifactReportProcessor.processArtifact( model, artifact, reporter, 
repository );
+        artifactReportProcessor.processArtifact( artifact, null, reporter );
         assertEquals( 1, reporter.getNumFailures() );
     }
 
@@ -118,17 +100,13 @@
      * location in the file system pom but instead matches the specified 
location in the packaged pom.
      */
     public void testFsPomArtifactMatchFailure()
-        throws IOException, ReportProcessorException, XmlPullParserException
+        throws IOException, XmlPullParserException
     {
-        ArtifactHandler handler = new DefaultArtifactHandler( "jar" );
-        VersionRange version = VersionRange.createFromVersion( "2.0" );
-        Artifact artifact =
-            new DefaultArtifact( "org.apache.maven", "maven-archiver", 
version, "compile", "jar", "", handler );
+        Artifact artifact = createArtifact( "org.apache.maven", 
"maven-archiver", "2.0" );
 
-        String path = 
"org/apache/maven/maven-archiver/2.0/maven-archiver-2.0.pom";
-        Model model = readPom( path );
-
-        artifactReportProcessor.processArtifact( model, artifact, reporter, 
repository );
+        Artifact pomArtifact = createArtifact( "org.apache.maven", 
"maven-archiver", "2.0", "pom" );
+        Model model = readPom( repository.pathOf( pomArtifact ) );
+        artifactReportProcessor.processArtifact( artifact, model, reporter );
         assertEquals( 1, reporter.getNumFailures() );
     }
 
@@ -154,17 +132,11 @@
      * location specified in the packaged pom but matches the location 
specified in the file system pom.
      */
     public void testPkgPomArtifactMatchFailure()
-        throws IOException, XmlPullParserException, ReportProcessorException
+        throws IOException, XmlPullParserException
     {
-        ArtifactHandler handler = new DefaultArtifactHandler( "jar" );
-        VersionRange version = VersionRange.createFromVersion( "2.1" );
-        Artifact artifact =
-            new DefaultArtifact( "org.apache.maven", "maven-monitor", version, 
"compile", "jar", "", handler );
-
-        String path = 
"org/apache/maven/maven-monitor/2.1/maven-monitor-2.1.pom";
-        Model model = readPom( path );
+        Artifact artifact = createArtifact( "org.apache.maven", 
"maven-monitor", "2.1" );
 
-        artifactReportProcessor.processArtifact( model, artifact, reporter, 
repository );
+        artifactReportProcessor.processArtifact( artifact, null, reporter );
         assertEquals( 1, reporter.getNumFailures() );
     }
 
@@ -173,17 +145,12 @@
      * location specified in the packaged pom and the location specified in 
the file system pom.
      */
     public void testBothPomArtifactMatchFailure()
-        throws IOException, XmlPullParserException, ReportProcessorException
+        throws IOException, XmlPullParserException
     {
-        ArtifactHandler handler = new DefaultArtifactHandler( "jar" );
-        VersionRange version = VersionRange.createFromVersion( "2.1" );
-        Artifact artifact =
-            new DefaultArtifact( "org.apache.maven", "maven-project", version, 
"compile", "jar", "", handler );
-
-        String path = 
"org/apache/maven/maven-project/2.1/maven-project-2.1.pom";
-        Model model = readPom( path );
+        Artifact artifact = createArtifact( "org.apache.maven", 
"maven-project", "2.1" );
 
-        artifactReportProcessor.processArtifact( model, artifact, reporter, 
repository );
+        artifactReportProcessor.processArtifact( artifact, null, reporter );
         assertEquals( 1, reporter.getNumFailures() );
     }
+
 }

Modified: 
maven/archiva/trunk/archiva-reports-standard/src/test/repository/org/apache/maven/maven-archiver/2.0/maven-archiver-2.0.pom
URL: 
http://svn.apache.org/viewvc/maven/archiva/trunk/archiva-reports-standard/src/test/repository/org/apache/maven/maven-archiver/2.0/maven-archiver-2.0.pom?view=diff&rev=441377&r1=441376&r2=441377
==============================================================================
--- 
maven/archiva/trunk/archiva-reports-standard/src/test/repository/org/apache/maven/maven-archiver/2.0/maven-archiver-2.0.pom
 (original)
+++ 
maven/archiva/trunk/archiva-reports-standard/src/test/repository/org/apache/maven/maven-archiver/2.0/maven-archiver-2.0.pom
 Thu Sep  7 22:16:51 2006
@@ -1,9 +1,5 @@
 <project>
-  <parent>
-    <artifactId>maven</artifactId>
-    <groupId>org.apache.maven</groupId>
-    <version>2.1</version>
-  </parent>
+  <groupId>org.apache.maven</groupId>
   <modelVersion>4.0.0</modelVersion>
   <artifactId>maven-archiver</artifactId>
   <name>Maven Archiver</name>

Modified: 
maven/archiva/trunk/archiva-webapp/src/main/webapp/WEB-INF/jsp/admin/configure.jsp
URL: 
http://svn.apache.org/viewvc/maven/archiva/trunk/archiva-webapp/src/main/webapp/WEB-INF/jsp/admin/configure.jsp?view=diff&rev=441377&r1=441376&r2=441377
==============================================================================
--- 
maven/archiva/trunk/archiva-webapp/src/main/webapp/WEB-INF/jsp/admin/configure.jsp
 (original)
+++ 
maven/archiva/trunk/archiva-webapp/src/main/webapp/WEB-INF/jsp/admin/configure.jsp
 Thu Sep  7 22:16:51 2006
@@ -31,7 +31,6 @@
   <ww:form method="post" action="saveConfiguration" namespace="/admin" 
validate="true">
     <ww:textfield name="indexPath" label="Index Directory" size="100" 
required="true"/>
     <ww:textfield name="indexerCronExpression" label="Indexing Schedule"/>
-    <ww:textfield name="reporterCronExpression" label="Reporting Schedule"/>
     <ww:hidden name="proxy.protocol" value="http"/>
     <ww:textfield name="proxy.host" label="HTTP Proxy Host"/>
     <ww:textfield name="proxy.port" label="HTTP Proxy Port"/>

Modified: 
maven/archiva/trunk/archiva-webapp/src/main/webapp/WEB-INF/jsp/admin/index.jsp
URL: 
http://svn.apache.org/viewvc/maven/archiva/trunk/archiva-webapp/src/main/webapp/WEB-INF/jsp/admin/index.jsp?view=diff&rev=441377&r1=441376&r2=441377
==============================================================================
--- 
maven/archiva/trunk/archiva-webapp/src/main/webapp/WEB-INF/jsp/admin/index.jsp 
(original)
+++ 
maven/archiva/trunk/archiva-webapp/src/main/webapp/WEB-INF/jsp/admin/index.jsp 
Thu Sep  7 22:16:51 2006
@@ -52,13 +52,6 @@
     <%-- TODO: a "delete index and run now" operation should be here too 
(really clean, remove deletions that didn't get picked up) --%>
     <td><a href="<ww:url action="runIndexer" />">Run Now</a></td>
   </tr>
-  <tr>
-    <th>Reporting Schedule</th>
-    <td>
-      <ww:property value="reporterCronExpression"/>
-    </td>
-    <td><a href="<ww:url action="runReporter" />">Run Now</a></td>
-  </tr>
 </table>
 
 <ww:set name="proxy" value="proxy"/>


Reply via email to