lenya-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From andr...@apache.org
Subject cvs commit: cocoon-lenya/src/test/org/apache/lenya/cms/publication DefaultSiteTreeTestCase.java
Date Fri, 30 May 2003 15:00:02 GMT
andreas     2003/05/30 08:00:02

  Modified:    src/test/org/apache/lenya/cms/publication
                        DefaultSiteTreeTestCase.java
  Log:
  catching SiteTreeException
  
  Revision  Changes    Path
  1.2       +21 -20    cocoon-lenya/src/test/org/apache/lenya/cms/publication/DefaultSiteTreeTestCase.java
  
  Index: DefaultSiteTreeTestCase.java
  ===================================================================
  RCS file: /home/cvs/cocoon-lenya/src/test/org/apache/lenya/cms/publication/DefaultSiteTreeTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DefaultSiteTreeTestCase.java	8 May 2003 08:38:19 -0000	1.1
  +++ DefaultSiteTreeTestCase.java	30 May 2003 15:00:02 -0000	1.2
  @@ -5,9 +5,6 @@
   import junit.framework.TestSuite;
   import junit.textui.TestRunner;
   
  -import org.apache.lenya.cms.publication.DefaultSiteTree;
  -import org.apache.lenya.cms.publication.Label;
  -
   /**
    * A test case testing org.apache.lenya.cms.publishing.DefaultSiteTree
    *
  @@ -15,7 +12,7 @@
    */
   public final class DefaultSiteTreeTestCase extends TestCase {
       private DefaultSiteTree sitetree;
  -    
  +
       /**
        * The main program for the DefaultSiteTreeTestCase class
        *
  @@ -37,25 +34,29 @@
       /**
        *
        */
  -     public DefaultSiteTreeTestCase(String test) {
  -         super(test);
  -	 try {
  -	     sitetree = new DefaultSiteTree("");
  -	     
  -	 } catch (Exception e) {
  -	     System.err.println(e);
  -	 }
  -     }
  -    
  +    public DefaultSiteTreeTestCase(String test) {
  +        super(test);
  +        try {
  +            sitetree = new DefaultSiteTree("");
  +
  +        } catch (Exception e) {
  +            System.err.println(e);
  +        }
  +    }
  +
       /**
        * Test if username exists
        */
       public void testNodeAddition() {
  -	Label label = new Label("Foo", null);
  -	Label[] labels = { label };
  -	sitetree.addNode("/tutorial", "foo", labels);
  -	// read the new sitetree and assert that it contains the new node
  +        Label label = new Label("Foo", null);
  +        Label[] labels = { label };
  +        try {
  +            sitetree.addNode("/tutorial", "foo", labels);
  +        } catch (SiteTreeException e) {
  +            // TODO Auto-generated catch block
  +            e.printStackTrace(System.err);
  +        }
  +        // read the new sitetree and assert that it contains the new node
   
       }
   }
  -
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-cvs-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-cvs-help@cocoon.apache.org


Mime
View raw message