Author: rfeng
Date: Thu Feb 21 08:48:22 2008
New Revision: 629867

URL: http://svn.apache.org/viewvc?rev=629867&view=rev
Log:
Fix the test case as now the system error is caught as ServiceRuntimeException

Modified:
    
incubator/tuscany/java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/DomainAPITestCase.java

Modified: 
incubator/tuscany/java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/DomainAPITestCase.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/DomainAPITestCase.java?rev=629867&r1=629866&r2=629867&view=diff
==============================================================================
--- 
incubator/tuscany/java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/DomainAPITestCase.java
 (original)
+++ 
incubator/tuscany/java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/DomainAPITestCase.java
 Thu Feb 21 08:48:22 2008
@@ -20,8 +20,6 @@
 package org.apache.tuscany.sca.itest.domain;
 
 
-import java.lang.reflect.UndeclaredThrowableException;
-
 import javax.xml.namespace.QName;
 
 import junit.framework.Assert;
@@ -29,14 +27,13 @@
 import org.apache.tuscany.sca.domain.SCADomain;
 import org.apache.tuscany.sca.domain.SCADomainFactory;
 import org.apache.tuscany.sca.domain.impl.SCADomainImpl;
-import org.apache.tuscany.sca.node.SCADomainFinder;
 import org.apache.tuscany.sca.node.SCANode;
 import org.apache.tuscany.sca.node.SCANodeFactory;
 import org.junit.AfterClass;
 import org.junit.BeforeClass;
 import org.junit.Test;
+import org.osoa.sca.ServiceRuntimeException;
 
-import calculator.AddService;
 import calculator.CalculatorService;
 
 /**
@@ -117,10 +114,8 @@
             try {
                 calculatorService.add(3, 2);
                 Assert.fail();
-            } catch (UndeclaredThrowableException ex){
+            } catch (ServiceRuntimeException ex){
                 // do nothing
-                
-                // TODO - can't this be a better exception than undeclared 
throwable
             }
             
             domain.start();
@@ -133,7 +128,7 @@
             try {
                 calculatorService.add(3, 2);
                 Assert.fail();
-            } catch (UndeclaredThrowableException ex){
+            } catch (ServiceRuntimeException ex){
                 // do nothing
             }            
             



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

Reply via email to