You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by hl...@apache.org on 2007/02/16 18:05:07 UTC
svn commit: r508493 - in /tapestry/tapestry5: tapestry-core/trunk/
tapestry-core/trunk/src/main/java/org/apache/tapestry/internal/services/
tapestry-core/trunk/src/site/apt/
tapestry-core/trunk/src/test/java/org/apache/tapestry/integration/
tapestry-io...
Author: hlship
Date: Fri Feb 16 09:05:06 2007
New Revision: 508493
URL: http://svn.apache.org/viewvc?view=rev&rev=508493
Log:
Tweak the POMs to better use the cobertura plugin.
Remove some temporary code used to track down the anomolous tapestry-core unit test failure.
Modified:
tapestry/tapestry5/tapestry-core/trunk/pom.xml
tapestry/tapestry5/tapestry-core/trunk/src/main/java/org/apache/tapestry/internal/services/ComponentClassResolverImpl.java
tapestry/tapestry5/tapestry-core/trunk/src/site/apt/index.apt
tapestry/tapestry5/tapestry-core/trunk/src/test/java/org/apache/tapestry/integration/IntegrationTests.java
tapestry/tapestry5/tapestry-ioc/trunk/pom.xml
tapestry/tapestry5/tapestry-project/trunk/pom.xml
Modified: tapestry/tapestry5/tapestry-core/trunk/pom.xml
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/tapestry-core/trunk/pom.xml?view=diff&rev=508493&r1=508492&r2=508493
==============================================================================
--- tapestry/tapestry5/tapestry-core/trunk/pom.xml (original)
+++ tapestry/tapestry5/tapestry-core/trunk/pom.xml Fri Feb 16 09:05:06 2007
@@ -79,6 +79,21 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
</plugin>
+ <!-- This gets the plugin to clean up the cobertura.ser file left
+ in the root directory. -->
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>cobertura-maven-plugin</artifactId>
+ <version>${cobertura-plugin-version}</version>
+ <executions>
+ <execution>
+ <id>clean</id>
+ <goals>
+ <goal>clean</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
</build>
<reporting>
@@ -86,8 +101,6 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
- <!-- Had a classloader problem with version 2.0.3 -->
- <!-- <version>2.0</version> -->
<configuration>
<!--
<tags>
@@ -110,8 +123,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>cobertura-maven-plugin</artifactId>
- <!-- Version 2.1-SNAPSHOT is broken. -->
- <version>2.0</version>
+ <version>${cobertura-plugin-version}</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Modified: tapestry/tapestry5/tapestry-core/trunk/src/main/java/org/apache/tapestry/internal/services/ComponentClassResolverImpl.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/tapestry-core/trunk/src/main/java/org/apache/tapestry/internal/services/ComponentClassResolverImpl.java?view=diff&rev=508493&r1=508492&r2=508493
==============================================================================
--- tapestry/tapestry5/tapestry-core/trunk/src/main/java/org/apache/tapestry/internal/services/ComponentClassResolverImpl.java (original)
+++ tapestry/tapestry5/tapestry-core/trunk/src/main/java/org/apache/tapestry/internal/services/ComponentClassResolverImpl.java Fri Feb 16 09:05:06 2007
@@ -176,18 +176,9 @@
String result = locate(pageName, _pageToClassName);
if (result == null)
- {
- // Having trouble tracking this down:
- System.err.format("Page '%s' not found in %s!\n\n", pageName, _pageToClassName);
-
- // I have an intuition its a race condition related to the browser asking for
- // "favicon.ico" but since everything is properly synchronized, I'm not quite sure
- // how that would happen.
-
throw new IllegalArgumentException(ServicesMessages.couldNotResolvePageName(
pageName,
_pageToClassName.keySet()));
- }
return result;
}
Modified: tapestry/tapestry5/tapestry-core/trunk/src/site/apt/index.apt
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/tapestry-core/trunk/src/site/apt/index.apt?view=diff&rev=508493&r1=508492&r2=508493
==============================================================================
--- tapestry/tapestry5/tapestry-core/trunk/src/site/apt/index.apt (original)
+++ tapestry/tapestry5/tapestry-core/trunk/src/site/apt/index.apt Fri Feb 16 09:05:06 2007
@@ -98,40 +98,40 @@
+----+
public class Login
{
- @Persist
- private String _userId;
-
- private String _password;
-
- @Component
- private Form _form;
-
- @InjectPage
- private Start _startPage;
-
- @Inject
- private LoginAuthenticator _authenticator;
-
- @OnEvent("submit")
- private Object doLogin()
- {
- if (_authenticator.isValidLogin(_userId, _password))
- return _startPage;
-
- // Stay on this page:
-
- _form.recordError("Invalid user name or password.");
-
- return null;
- }
-
- public String getUserId() { return _userId; }
-
- public String getPassword() { return _password; }
-
- public void setUserId(String userId) { _userId = userId; }
-
- public void setPassword(String password) { _password = password; }
+ @Persist
+ private String _userId;
+
+ private String _password;
+
+ @Component
+ private Form _form;
+
+ @InjectPage
+ private Start _startPage;
+
+ @Inject
+ private LoginAuthenticator _authenticator;
+
+ @OnEvent("submit")
+ private Object doLogin()
+ {
+ if (_authenticator.isValidLogin(_userId, _password))
+ return _startPage;
+
+ // Stay on this page:
+
+ _form.recordError("Invalid user name or password.");
+
+ return null;
+ }
+
+ public String getUserId() { return _userId; }
+
+ public String getPassword() { return _password; }
+
+ public void setUserId(String userId) { _userId = userId; }
+
+ public void setPassword(String password) { _password = password; }
}
+----+
Modified: tapestry/tapestry5/tapestry-core/trunk/src/test/java/org/apache/tapestry/integration/IntegrationTests.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/tapestry-core/trunk/src/test/java/org/apache/tapestry/integration/IntegrationTests.java?view=diff&rev=508493&r1=508492&r2=508493
==============================================================================
--- tapestry/tapestry5/tapestry-core/trunk/src/test/java/org/apache/tapestry/integration/IntegrationTests.java (original)
+++ tapestry/tapestry5/tapestry-core/trunk/src/test/java/org/apache/tapestry/integration/IntegrationTests.java Fri Feb 16 09:05:06 2007
@@ -504,7 +504,8 @@
_selenium.start();
- // Warm things up:
+ // Warm things up; this prevents errors when the first test runs. Seems to be a problem
+ // with Selenium: inside the JavaScript or the server code.
_selenium.open(BASE_URL);
}
@@ -864,25 +865,11 @@
@Test
public void null_grid() throws Exception
{
- // Been having problems with very spurious failures of this test. Troubling, and it has
- // repairman
- // syndrome; only happens during a full suite, where I can't pick out the problem. These
- // calls to System.error
- // seem to have "fixed" it. I think TestNG may be running null_grid() first.
-
- System.err.println("****\n\n\nNULL GRID START\n\n****\n\n");
-
_selenium.open(BASE_URL);
- // Let's see if sleeping for a half second is enough.
-
- Thread.sleep(5000);
-
clickAndWait("link=Null Grid");
assertTextPresent("There is no data to display.");
-
- System.err.println("****\n\n\nNULL GRID END\n\n****\n\n");
}
}
Modified: tapestry/tapestry5/tapestry-ioc/trunk/pom.xml
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/tapestry-ioc/trunk/pom.xml?view=diff&rev=508493&r1=508492&r2=508493
==============================================================================
--- tapestry/tapestry5/tapestry-ioc/trunk/pom.xml (original)
+++ tapestry/tapestry5/tapestry-ioc/trunk/pom.xml Fri Feb 16 09:05:06 2007
@@ -1,4 +1,5 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.apache.tapestry</groupId>
@@ -61,15 +62,30 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
- </plugin>
+ </plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
- </plugin>
+ </plugin>
+ <!-- This gets the plugin to clean up the cobertura.ser file left
+ in the root directory. -->
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>cobertura-maven-plugin</artifactId>
+ <version>${cobertura-plugin-version}</version>
+ <executions>
+ <execution>
+ <id>clean</id>
+ <goals>
+ <goal>clean</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
</build>
<reporting>
- <plugins>
+ <plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
@@ -98,12 +114,12 @@
<groupId>org.codehaus.mojo</groupId>
<artifactId>cobertura-maven-plugin</artifactId>
<!-- Version 2.1-SNAPSHOT is broken. -->
- <version>2.0</version>
- </plugin>
+ <version>${cobertura-plugin-version}</version>
+ </plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-report-plugin</artifactId>
- </plugin>
+ </plugin>
</plugins>
</reporting>
</project>
Modified: tapestry/tapestry5/tapestry-project/trunk/pom.xml
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/tapestry-project/trunk/pom.xml?view=diff&rev=508493&r1=508492&r2=508493
==============================================================================
--- tapestry/tapestry5/tapestry-project/trunk/pom.xml (original)
+++ tapestry/tapestry5/tapestry-project/trunk/pom.xml Fri Feb 16 09:05:06 2007
@@ -189,8 +189,6 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
- <!-- HLS added version number on 11 Jan 2007 when builds started breaking. -->
- <version>2.0-beta-1</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
@@ -198,10 +196,6 @@
</configuration>
</plugin>
<plugin>
- <artifactId>maven-site-plugin</artifactId>
- <version>2.0-beta-5</version>
- </plugin>
- <plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.8-SNAPSHOT</version>
@@ -223,6 +217,9 @@
</archive>
</configuration>
</plugin>
+
+
+
</plugins>
</pluginManagement>
@@ -323,5 +320,10 @@
</url>
</snapshotRepository>
</distributionManagement>
+
+ <properties>
+ <!-- Version 2.1-SNAPSHOT lists everything as 100% covered, wierd. -->
+ <cobertura-plugin-version>2.0</cobertura-plugin-version>
+ </properties>
</project>