CVS: plexus-container-new/src/java/org/apache/plexus PlexusTestCase.java,1.7,1.8
[email protected] Fri, 23 May 2003 10:59:04 -0500
| Newsgroups | gmane.comp.java.plexus.devel |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/plexus/plexus-container-new/src/java/org/apache/plexus
In directory eng.werken.com:/tmp/cvs-serv7543
Modified Files:
PlexusTestCase.java
Log Message:
o The test case configuration cannot be null.
Index: PlexusTestCase.java
===================================================================
RCS file: /cvsroot/plexus/plexus-container-new/src/java/org/apache/plexus/PlexusTestCase.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- PlexusTestCase.java 23 May 2003 00:38:30 -0000 1.7
+++ PlexusTestCase.java 23 May 2003 15:59:02 -0000 1.8
@@ -124,8 +124,13 @@
fail( e.getMessage() );
}
+ if ( configuration == null )
+ {
+ throw new IllegalStateException( "The configuration for your plexus test case cannot be null. " );
+ }
+
container = new DefaultPlexusContainer();
- container.addContextValue( "basedir", System.getProperty( "basedir" ) );
+ container.addContextValue( "basedir", basedir );
container.addContextValue( "plexus.home", System.getProperty( "plexus.home" ) );
container.setConfigurationResource( new InputStreamReader( configuration ) );
container.initialize();