You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by sl...@apache.org on 2008/05/21 16:32:29 UTC

svn commit: r658706 [8/8] - in /incubator/tuscany/java/sca: itest/validation/ itest/validation/src/main/java/binding/ itest/validation/src/main/java/binding/ejb/ itest/validation/src/main/java/binding/ejb/account/ itest/validation/src/main/java/binding...

Added: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java?rev=658706&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java Wed May 21 07:32:22 2008
@@ -0,0 +1,60 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+package impl.java;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class ContributionResolveExceptionTestCase extends TestCase {
+	
+	private CustomCompositeBuilder customDomain;
+
+    @Override
+    protected void setUp() throws Exception 
+    {
+    	customDomain = CustomCompositeBuilder.getInstance();
+        try {        	
+        	customDomain.loadContribution("src/main/resources/impl/java/ContributionResolveException/Calculator.composite", 
+        			"TestContribution", "src/main/resources/impl/java/ContributionResolveException/");        	            
+        } catch (Exception ex){
+            //throw ex;
+        }
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        //nothing to do
+    }
+
+    public void testCalculator() {
+    	Monitor monitor = customDomain.getMonitorInstance();
+    	Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+        
+    	
+    	//assertNotNull(problem);
+        //assertEquals("ContributionResolveException", problem.getMessageId());
+    }
+}

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java?rev=658706&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java Wed May 21 07:32:22 2008
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+package impl.spring;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class ContributionResolveExceptionTestCase extends TestCase {
+
+	private CustomCompositeBuilder customDomain;
+	
+    @Override
+    protected void setUp() throws Exception 
+    {
+    	customDomain = CustomCompositeBuilder.getInstance();
+        try {        	
+        	customDomain.loadContribution("src/main/resources/impl/spring/ContributionResolveException/SpringHelloWorld.composite", 
+        			"TestContribution", "src/main/resources/impl/spring/ContributionResolveException/");        	            
+        } catch (Exception ex){
+            //throw ex;
+        }
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        //node.stop();
+    }
+
+    public void testCalculator() {
+    	Monitor monitor = customDomain.getMonitorInstance();
+    	Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+        
+    	assertNotNull(problem);
+        assertEquals("ContributionResolveException", problem.getMessageId());  
+    }
+}

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java?rev=658706&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java Wed May 21 07:32:22 2008
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+package impl.spring;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class LocationAttributeMissingTestCase extends TestCase {
+
+	private CustomCompositeBuilder customDomain;
+	
+    @Override
+    protected void setUp() throws Exception 
+    {
+    	customDomain = CustomCompositeBuilder.getInstance();
+        try {        	
+        	customDomain.loadContribution("src/main/resources/impl/spring/LocationAttributeMissing/SpringHelloWorld.composite", 
+        			"TestContribution", "src/main/resources/impl/spring/LocationAttributeMissing/");        	            
+        } catch (Exception ex){
+            //throw ex;
+        }
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        //node.stop();
+    }
+
+    public void testCalculator() {
+    	Monitor monitor = customDomain.getMonitorInstance();
+    	Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+        
+    	assertNotNull(problem);
+        assertEquals("LocationAttributeMissing", problem.getMessageId());  
+    }
+}

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java?rev=658706&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java Wed May 21 07:32:22 2008
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+package impl.spring;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class UnableToResolveComponentTypeTestCase extends TestCase {
+
+	private CustomCompositeBuilder customDomain;
+	
+    @Override
+    protected void setUp() throws Exception 
+    {
+    	customDomain = CustomCompositeBuilder.getInstance();
+        try {        	
+        	customDomain.loadContribution("src/main/resources/impl/spring/UnableToResolveComponentType/SpringHelloWorld.composite", 
+        			"TestContribution", "src/main/resources/impl/spring/UnableToResolveComponentType/");        	            
+        } catch (Exception ex){
+            //throw ex;
+        }
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        //node.stop();
+    }
+
+    public void testCalculator() {
+    	Monitor monitor = customDomain.getMonitorInstance();
+    	Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+        
+    	//assertNotNull(problem);
+        //assertEquals("UnableToResolveComponentType", problem.getMessageId());  
+    }
+}

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java?rev=658706&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java Wed May 21 07:32:22 2008
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+package impl.xquery;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class CouldNotLocateFileTestCase extends TestCase {
+
+	private CustomCompositeBuilder customDomain;
+	
+    @Override
+    protected void setUp() throws Exception 
+    {
+    	customDomain = CustomCompositeBuilder.getInstance();
+        try {        	
+        	customDomain.loadContribution("src/main/resources/impl/xquery/CouldNotLocateFile/HelloWorld.composite", 
+        			"TestContribution", "src/main/resources/impl/xquery/CouldNotLocateFile/");        	            
+        } catch (Exception ex){
+            //throw ex;
+        }
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        //node.stop();
+    }
+
+    public void testCalculator() {
+    	Monitor monitor = customDomain.getMonitorInstance();
+    	Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+        
+    	assertNotNull(problem);
+        assertEquals("CouldNotLocateFile", problem.getMessageId());  
+    }
+}

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java?rev=658706&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java Wed May 21 07:32:22 2008
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+package impl.xquery;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class LocationAttributeMissingTestCase extends TestCase {
+
+	private CustomCompositeBuilder customDomain;
+	
+    @Override
+    protected void setUp() throws Exception 
+    {
+    	customDomain = CustomCompositeBuilder.getInstance();
+        try {        	
+        	customDomain.loadContribution("src/main/resources/impl/xquery/LocationAttributeMissing/HelloWorld.composite", 
+        			"TestContribution", "src/main/resources/impl/xquery/LocationAttributeMissing/");        	            
+        } catch (Exception ex){
+            //throw ex;
+        }
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        //node.stop();
+    }
+
+    public void testCalculator() {
+    	Monitor monitor = customDomain.getMonitorInstance();
+    	Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+        
+    	assertNotNull(problem);
+        assertEquals("LocationAttributeMissing", problem.getMessageId());  
+    }
+}

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java?rev=658706&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java Wed May 21 07:32:22 2008
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+package interfacejava.xml;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class ClassNotFoundTestCase extends TestCase {
+
+	private CustomCompositeBuilder customDomain;
+
+    @Override
+    protected void setUp() throws Exception 
+    {
+    	customDomain = CustomCompositeBuilder.getInstance();
+        try {
+        	customDomain.loadContribution("src/main/resources/interfacejava/xml/ClassNotFoundException/Calculator.composite", 
+        			"TestContribution", "src/main/resources/interfacejava/xml/ClassNotFoundException/");
+        } catch (Exception ex){
+            //throw ex;
+        }
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        //node.stop();
+    }
+
+    public void testCalculator() {
+    	Monitor monitor = customDomain.getMonitorInstance();
+    	Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+        
+    	assertNotNull(problem);
+        assertEquals("ClassNotFoundException", problem.getMessageId()); 
+    }
+}

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java?rev=658706&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java Wed May 21 07:32:22 2008
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+package interfacejava.xml;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class ContributionResolveExceptionTestCase extends TestCase {
+
+	private CustomCompositeBuilder customDomain;
+	
+    @Override
+    protected void setUp() throws Exception 
+    {
+    	customDomain = CustomCompositeBuilder.getInstance();
+        try {        	
+        	customDomain.loadContribution("src/main/resources/interfacejava/xml/ContributionResolveException/Calculator.composite", 
+        			"TestContribution", "src/main/resources/interfacejava/xml/ContributionResolveException/");        	            
+        } catch (Exception ex){
+            throw ex;
+        }
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        //node.stop();
+    }
+
+    public void testCalculator() {
+    	Monitor monitor = customDomain.getMonitorInstance();
+    	Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+        
+    	//assertNotNull(problem);
+        //assertEquals("ContributionResolveException", problem.getMessageId());  
+    }
+}

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java?rev=658706&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java Wed May 21 07:32:22 2008
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+package interfacewsdl.xml;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class InvalidWSDLInterfaceAttrTestCase extends TestCase {
+
+	private CustomCompositeBuilder customDomain;
+	
+    @Override
+    protected void setUp() throws Exception 
+    {
+    	customDomain = CustomCompositeBuilder.getInstance();
+        try {        	
+        	customDomain.loadContribution("src/main/resources/interfacewsdl/xml/InvalidWSDLInterfaceAttr/Calculator.composite", 
+        			"TestContribution", "src/main/resources/interfacewsdl/xml/InvalidWSDLInterfaceAttr/");        	            
+        } catch (Exception ex){
+            //throw ex;
+        }
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        //node.stop();
+    }
+
+    public void testCalculator() {
+    	Monitor monitor = customDomain.getMonitorInstance();
+    	Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+        
+    	assertNotNull(problem);
+        assertEquals("InvalidWSDLInterfaceAttr", problem.getMessageId());  
+    }
+}

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Modified: incubator/tuscany/java/sca/modules/interface-java-xml/src/main/java/org/apache/tuscany/sca/interfacedef/java/xml/JavaInterfaceProcessor.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/interface-java-xml/src/main/java/org/apache/tuscany/sca/interfacedef/java/xml/JavaInterfaceProcessor.java?rev=658706&r1=658705&r2=658706&view=diff
==============================================================================
--- incubator/tuscany/java/sca/modules/interface-java-xml/src/main/java/org/apache/tuscany/sca/interfacedef/java/xml/JavaInterfaceProcessor.java (original)
+++ incubator/tuscany/java/sca/modules/interface-java-xml/src/main/java/org/apache/tuscany/sca/interfacedef/java/xml/JavaInterfaceProcessor.java Wed May 21 07:32:22 2008
@@ -26,6 +26,7 @@
 import javax.xml.stream.XMLStreamReader;
 import javax.xml.stream.XMLStreamWriter;
 
+import org.apache.tuscany.sca.assembly.builder.impl.ProblemImpl;
 import org.apache.tuscany.sca.assembly.xml.Constants;
 import org.apache.tuscany.sca.contribution.ModelFactoryExtensionPoint;
 import org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor;
@@ -39,6 +40,8 @@
 import org.apache.tuscany.sca.interfacedef.java.JavaInterfaceContract;
 import org.apache.tuscany.sca.interfacedef.java.JavaInterfaceFactory;
 import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.Problem.Severity;
 
 /**
  *
@@ -117,6 +120,8 @@
                 classReference = resolver.resolveModel(ClassReference.class, classReference);
                 Class javaClass = classReference.getJavaClass();
                 if (javaClass == null) {
+                    Problem problem = new ProblemImpl(this.getClass().getName(), "interface-javaxml-validation-messages", Severity.ERROR, javaInterface, "ClassNotFoundException", javaInterface.getName());
+                    monitor.problem(problem);
                     throw new ContributionResolveException(new ClassNotFoundException(javaInterface.getName()));
                 }
                 try {

Modified: incubator/tuscany/java/sca/modules/interface-java-xml/src/main/resources/interface-javaxml-validation-messages.properties
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/interface-java-xml/src/main/resources/interface-javaxml-validation-messages.properties?rev=658706&r1=658705&r2=658706&view=diff
==============================================================================
--- incubator/tuscany/java/sca/modules/interface-java-xml/src/main/resources/interface-javaxml-validation-messages.properties (original)
+++ incubator/tuscany/java/sca/modules/interface-java-xml/src/main/resources/interface-javaxml-validation-messages.properties Wed May 21 07:32:22 2008
@@ -20,25 +20,3 @@
 #
 ClassNotFoundException = Class Not Found Exception: {0}
 ContributionResolveException = ContributionResolveException occured due to :
-#
-#
-#    Licensed to the Apache Software Foundation (ASF) under one
-#    or more contributor license agreements. See the NOTICE file
-#    distributed with this work for additional information
-#    regarding copyright ownership. The ASF licenses this file
-#    to you under the Apache License, Version 2.0 (the
-#    "License"); you may not use this file except in compliance
-#    with the License. You may obtain a copy of the License at
-#
-#    http://www.apache.org/licenses/LICENSE-2.0
-#
-#    Unless required by applicable law or agreed to in writing,
-#    software distributed under the License is distributed on an
-#    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-#    KIND, either express or implied. See the License for the
-#    specific language governing permissions and limitations
-#    under the License.
-#
-#
-ClassNotFoundException = Class Not Found Exception: {0}
-ContributionResolveException = ContributionResolveException occured due to :
\ No newline at end of file