[cvs] expresso/expresso-web/WEB-INF/src/com/jcorporate
AllProjectsTestSuite.java
JCorporate Ltd
jcorp at jcorp2.servlets.net
Fri Sep 17 17:04:30 PDT 2004
Update of /home/javacorp/.cvs/expresso/expresso/expresso-web/WEB-INF/src/com/jcorporate
In directory jcorp2.servlets.net:/tmp/cvs-serv12174
Modified Files:
AllProjectsTestSuite.java
Log Message:
Yves Henri AMAIZO's contributions.
Commited by Raul Davidovich on 20040918
Index: AllProjectsTestSuite.java
===================================================================
RCS file: /home/javacorp/.cvs/expresso/expresso/expresso-web/WEB-INF/src/com/jcorporate/AllProjectsTestSuite.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** AllProjectsTestSuite.java 3 Jun 2003 06:12:11 -0000 1.7
--- AllProjectsTestSuite.java 18 Sep 2004 00:04:28 -0000 1.8
***************
*** 2,6 ****
* The Jcorporate Apache Style Software License, Version 1.2 05-07-2002
*
! * Copyright (c) 1995-2002 Jcorporate Ltd. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
--- 2,6 ----
* The Jcorporate Apache Style Software License, Version 1.2 05-07-2002
*
! * Copyright (c) 1995-2002 Jcorporate Ltd. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
***************
*** 22,46 ****
* Alternately, this acknowledgment may appear in the software itself,
* if and wherever such third-party acknowledgments normally appear.
! *
* 4. "Jcorporate" and product names such as "Expresso" must
* not be used to endorse or promote products derived from this
* software without prior written permission. For written permission,
* please contact info at jcorporate.com.
! *
* 5. Products derived from this software may not be called "Expresso",
! * or other Jcorporate product names; nor may "Expresso" or other
! * Jcorporate product names appear in their name, without prior
* written permission of Jcorporate Ltd.
! *
! * 6. No product derived from this software may compete in the same
* market space, i.e. framework, without prior written permission
* of Jcorporate Ltd. For written permission, please contact
* partners at jcorporate.com.
! *
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL JCORPORATE LTD OR ITS CONTRIBUTORS
! * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
* TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
--- 22,46 ----
* Alternately, this acknowledgment may appear in the software itself,
* if and wherever such third-party acknowledgments normally appear.
! *
* 4. "Jcorporate" and product names such as "Expresso" must
* not be used to endorse or promote products derived from this
* software without prior written permission. For written permission,
* please contact info at jcorporate.com.
! *
* 5. Products derived from this software may not be called "Expresso",
! * or other Jcorporate product names; nor may "Expresso" or other
! * Jcorporate product names appear in their name, without prior
* written permission of Jcorporate Ltd.
! *
! * 6. No product derived from this software may compete in the same
* market space, i.e. framework, without prior written permission
* of Jcorporate Ltd. For written permission, please contact
* partners at jcorporate.com.
! *
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL JCORPORATE LTD OR ITS CONTRIBUTORS
! * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
* TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
***************
*** 54,81 ****
* This software consists of voluntary contributions made by many
* individuals on behalf of the Jcorporate Ltd. Contributions back
! * to the project(s) are encouraged when you make modifications.
! * Please send them to support at jcorporate.com. For more information
! * on Jcorporate Ltd. and its products, please see
* <http://www.jcorporate.com/>.
*
! * Portions of this software are based upon other open source
! * products and are subject to their respective licenses.
*/
package com.jcorporate;
! import com.jcorporate.expresso.services.test.TestSystemInitializer;
! import junit.framework.TestSuite;
! import org.apache.log4j.Logger;
! import java.lang.reflect.Method;
/**
! * Test suite for all the projects
* @author Michael Rimov
* @version $Revision$ $Date$
*/
-
/**
* Class for allowing testing of all jcorporate's products.
--- 54,86 ----
* This software consists of voluntary contributions made by many
* individuals on behalf of the Jcorporate Ltd. Contributions back
! * to the project(s) are encouraged when you make modifications.
! * Please send them to support at jcorporate.com. For more information
! * on Jcorporate Ltd. and its products, please see
* <http://www.jcorporate.com/>.
*
! * Portions of this software are based upon other open source
! * products and are subject to their respective licenses.
*/
package com.jcorporate;
! import com.jcorporate.expresso.core.logging.LogManager;
! import com.jcorporate.expresso.services.test.*;
! import java.lang.reflect.*;
!
! import junit.framework.*;
!
! import org.apache.log4j.Category;
/**
! * Title: Expresso Project
! * Description:
! * Copyright: Copyright (c) 2001
! * Company: Jcorporate
* @author Michael Rimov
* @version $Revision$ $Date$
*/
/**
* Class for allowing testing of all jcorporate's products.
***************
*** 83,107 ****
*/
public class AllProjectsTestSuite
! extends TestSuite {
! static Logger log = Logger.getLogger(AllProjectsTestSuite.class);
public AllProjectsTestSuite()
! throws Exception {
TestSystemInitializer.setUp();
}
public AllProjectsTestSuite(String name)
! throws Exception {
super(name);
TestSystemInitializer.setUp();
}
public static void main(String[] args)
! throws Exception {
//Set the system properties we need
junit.textui.TestRunner.run(suite());
}
-
/**
* This differes in that only test suites that are located in the project
--- 88,113 ----
*/
public class AllProjectsTestSuite
! extends TestSuite {
! static Category log = null;
public AllProjectsTestSuite()
! throws Exception {
TestSystemInitializer.setUp();
+ setupLog();
}
public AllProjectsTestSuite(String name)
! throws Exception {
super(name);
TestSystemInitializer.setUp();
+ setupLog();
}
public static void main(String[] args)
! throws Exception {
//Set the system properties we need
junit.textui.TestRunner.run(suite());
}
/**
* This differes in that only test suites that are located in the project
***************
*** 110,114 ****
*/
public static junit.framework.Test suite()
! throws Exception {
AllProjectsTestSuite ts = new AllProjectsTestSuite("All JCorporate Projects Test Suite");
addTestSuite("com.jcorporate.expresso.core.ExpressoTestSuite", ts);
--- 116,120 ----
*/
public static junit.framework.Test suite()
! throws Exception {
AllProjectsTestSuite ts = new AllProjectsTestSuite("All JCorporate Projects Test Suite");
addTestSuite("com.jcorporate.expresso.core.ExpressoTestSuite", ts);
***************
*** 120,124 ****
return ts;
}
-
/**
* Adds a test suite _IF_ the class exists in the classpath
--- 126,129 ----
***************
*** 129,133 ****
Class c = Class.forName(className);
Method m = c.getMethod("suite", null);
! ts.addTest((junit.framework.Test) m.invoke(null, null));
} catch (Exception e) {
log.warn("Unable to load test suite " + className, e);
--- 134,138 ----
Class c = Class.forName(className);
Method m = c.getMethod("suite", null);
! ts.addTest((junit.framework.Test)m.invoke(null, null));
} catch (Exception e) {
log.warn("Unable to load test suite " + className, e);
***************
*** 135,137 ****
--- 140,147 ----
} /* addTestSuite(String, TestSuite) */
+
+ public void setupLog() {
+ LogManager.instantiate();
+ log = Category.getInstance("expresso.test.AllProjectsTestSuite");
+ }
}
More information about the cvs
mailing list