martinc     2004/12/08 21:23:14

  Modified:    chain/src/test/org/apache/commons/chain/impl
                        CatalogFactoryBaseTestCase.java
  Log:
  Make sure that testPristine() comes first. Relying on the order of methods
  in the source being the order in which they are called is not exactly a
  best practice, but on the eve of a 1.0 release, switching the order of a
  couple of methods is the most expedient way to resolve the failing tests.
  
  Revision  Changes    Path
  1.3       +11 -11    
jakarta-commons/chain/src/test/org/apache/commons/chain/impl/CatalogFactoryBaseTestCase.java
  
  Index: CatalogFactoryBaseTestCase.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-commons/chain/src/test/org/apache/commons/chain/impl/CatalogFactoryBaseTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- CatalogFactoryBaseTestCase.java   18 Oct 2004 01:09:06 -0000      1.2
  +++ CatalogFactoryBaseTestCase.java   9 Dec 2004 05:23:14 -0000       1.3
  @@ -86,26 +86,26 @@
   
   
       /**
  -     * <p>Test the default [EMAIL PROTECTED] Catalog} instance.</p>
  +     * <p>Test a pristine instance of [EMAIL PROTECTED] CatalogFactory}.</p>
        */
  -    public void testDefaultCatalog() {
  +    public void testPristine() {
   
  -        Catalog catalog = new CatalogBase();
  -        factory.setCatalog(catalog);
  -        assertTrue(catalog == factory.getCatalog());
  +        assertNotNull(factory);
  +        assertNull(factory.getCatalog());
  +        assertNull(factory.getCatalog("foo"));
           assertEquals(0, getCatalogCount());
   
       }
   
   
       /**
  -     * <p>Test a pristine instance of [EMAIL PROTECTED] CatalogFactory}.</p>
  +     * <p>Test the default [EMAIL PROTECTED] Catalog} instance.</p>
        */
  -    public void testPristine() {
  +    public void testDefaultCatalog() {
   
  -        assertNotNull(factory);
  -        assertNull(factory.getCatalog());
  -        assertNull(factory.getCatalog("foo"));
  +        Catalog catalog = new CatalogBase();
  +        factory.setCatalog(catalog);
  +        assertTrue(catalog == factory.getCatalog());
           assertEquals(0, getCatalogCount());
   
       }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to