diff options
Diffstat (limited to '')
90 files changed, 134 insertions, 195 deletions
diff --git a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/ContributionReadException.java b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/ContributionReadException.java index 9b0d51eb59..55999fe27d 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/ContributionReadException.java +++ b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/ContributionReadException.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class ContributionReadException extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ContributionReadException", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/PolicyImplValidationException.java b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/PolicyImplValidationException.java index e8476991a9..5ab65b2f64 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/PolicyImplValidationException.java +++ b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/PolicyImplValidationException.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class PolicyImplValidationException extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("PolicyImplValidationException", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/PolicyServiceValidationException.java b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/PolicyServiceValidationException.java index 8ae156d63e..52803411cf 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/PolicyServiceValidationException.java +++ b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/PolicyServiceValidationException.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class PolicyServiceValidationException extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("PolicyServiceValidationException", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedBindingElement.java b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedBindingElement.java index d757ff98dd..8adf1aa2aa 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedBindingElement.java +++ b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedBindingElement.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class UnexpectedBindingElement extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnexpectedBindingElement", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedImplementationElement.java b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedImplementationElement.java index 9a231a18c7..2790cd0a6c 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedImplementationElement.java +++ b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedImplementationElement.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class UnexpectedImplementationElement extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnexpectedImplementationElement", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedInterfaceElement.java b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedInterfaceElement.java index 4ae88b9ba3..c6daaebfe5 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedInterfaceElement.java +++ b/branches/sca-equinox/itest/validation/src/test/java/assembly/xml/UnexpectedInterfaceElement.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; /** @@ -51,7 +50,7 @@ public class UnexpectedInterfaceElement extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnexpectedInterfaceElement", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/ejb/UnknownEJBSessionTypeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/ejb/UnknownEJBSessionTypeTestCase.java index ff94ad7b93..204034737b 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/ejb/UnknownEJBSessionTypeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/ejb/UnknownEJBSessionTypeTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -59,7 +58,7 @@ public class UnknownEJBSessionTypeTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnknownEJBSessionType", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/ejb/UnknownEJBVersionTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/ejb/UnknownEJBVersionTestCase.java index a192674aeb..ff2e413ab7 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/ejb/UnknownEJBVersionTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/ejb/UnknownEJBVersionTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -58,7 +57,7 @@ public class UnknownEJBVersionTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnknownEJBVersion", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessActivationSpecTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessActivationSpecTestCase.java index e0e5347d96..1632f95689 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessActivationSpecTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessActivationSpecTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class DoesntProcessActivationSpecTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DoesntProcessActivationSpec", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessDestinationTypeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessDestinationTypeTestCase.java index 9e08afec09..054f5a6035 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessDestinationTypeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessDestinationTypeTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class DoesntProcessDestinationTypeTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DoesntProcessDestinationType", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessHeadersTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessHeadersTestCase.java index ed96072780..f3f61ec04b 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessHeadersTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessHeadersTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.junit.Ignore; import domain.CustomCompositeBuilder; @@ -54,7 +53,7 @@ public class DoesntProcessHeadersTestCase extends TestCase { @Ignore("TUSCANY-2532") public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); // assertEquals("DoesntProcessHeaders", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResourceAdapterTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResourceAdapterTestCase.java index a2a5b0b872..76d8a63b51 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResourceAdapterTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResourceAdapterTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class DoesntProcessResourceAdapterTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DoesntProcessResourceAdapter", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseActivationSpecTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseActivationSpecTestCase.java index 64b41623de..95c108e6db 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseActivationSpecTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseActivationSpecTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class DoesntProcessResponseActivationSpecTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DoesntProcessResponseActivationSpec", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseConnectionFactoryTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseConnectionFactoryTestCase.java index 86fbe51dad..2f66bbfe0c 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseConnectionFactoryTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseConnectionFactoryTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class DoesntProcessResponseConnectionFactoryTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DoesntProcessResponseConnectionFactory", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseDestinationTypeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseDestinationTypeTestCase.java index 6e884c41cd..decf234753 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseDestinationTypeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/DoesntProcessResponseDestinationTypeTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class DoesntProcessResponseDestinationTypeTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DoesntProcessResponseDestinationType", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidCorrelationSchemeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidCorrelationSchemeTestCase.java index c237f8af18..445a41700b 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidCorrelationSchemeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidCorrelationSchemeTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class InvalidCorrelationSchemeTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("InvalidCorrelationScheme", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidJMSDeliveryModeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidJMSDeliveryModeTestCase.java index 52dc7e5795..531573a0aa 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidJMSDeliveryModeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidJMSDeliveryModeTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor;
import org.apache.tuscany.sca.monitor.Problem;
-import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl;
import domain.CustomCompositeBuilder;
@@ -52,7 +51,7 @@ public class InvalidJMSDeliveryModeTestCase extends TestCase { public void testCalculator() {
Monitor monitor = customDomain.getMonitorInstance();
- Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+ Problem problem = monitor.getLastProblem();
assertNotNull(problem);
assertEquals("InvalidJMSDeliveryMode", problem.getMessageId());
diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidJMSPriorityTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidJMSPriorityTestCase.java index a93df290c3..758e19d264 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidJMSPriorityTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidJMSPriorityTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor;
import org.apache.tuscany.sca.monitor.Problem;
-import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl;
import domain.CustomCompositeBuilder;
@@ -52,7 +51,7 @@ public class InvalidJMSPriorityTestCase extends TestCase { public void testCalculator() {
Monitor monitor = customDomain.getMonitorInstance();
- Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+ Problem problem = monitor.getLastProblem();
assertNotNull(problem);
assertEquals("InvalidJMSPriority", problem.getMessageId());
diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidResponseDestinationTypeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidResponseDestinationTypeTestCase.java index 949ec02134..96319438b6 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidResponseDestinationTypeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/InvalidResponseDestinationTypeTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class InvalidResponseDestinationTypeTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("InvalidResponseDestinationType", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingActivationSpecNameTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingActivationSpecNameTestCase.java index a974ef0db4..a2a4caa0b0 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingActivationSpecNameTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingActivationSpecNameTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class MissingActivationSpecNameTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("MissingActivationSpecName", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingConnectionFactoryNameTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingConnectionFactoryNameTestCase.java index adbaa50dc0..0d91afd7e6 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingConnectionFactoryNameTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingConnectionFactoryNameTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class MissingConnectionFactoryNameTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("MissingConnectionFactoryName", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingResponseActivationSpecTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingResponseActivationSpecTestCase.java index 4bba6b74de..048fcc7d43 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingResponseActivationSpecTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingResponseActivationSpecTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class MissingResponseActivationSpecTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("MissingResponseActivationSpec", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingResponseConnectionFactoryTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingResponseConnectionFactoryTestCase.java index 8f4fc1a739..856c9f3b27 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingResponseConnectionFactoryTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MissingResponseConnectionFactoryTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class MissingResponseConnectionFactoryTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("MissingResponseConnectionFactory", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MustStartWithSchemaTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MustStartWithSchemaTestCase.java index d9e1c782a8..b584cb8d94 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MustStartWithSchemaTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/MustStartWithSchemaTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class MustStartWithSchemaTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("MustStartWithSchema", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnexpectedElementTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnexpectedElementTestCase.java index 3e4e36d839..ae26008564 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnexpectedElementTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnexpectedElementTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class UnexpectedElementTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnexpectedElement", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnexpectedResponseElementTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnexpectedResponseElementTestCase.java index 60ea47a85f..fedc1f7530 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnexpectedResponseElementTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnexpectedResponseElementTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class UnexpectedResponseElementTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnexpectedResponseElement", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnknownTokenInURITestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnknownTokenInURITestCase.java index 6a75a35f99..d94643cbc9 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnknownTokenInURITestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/jms/UnknownTokenInURITestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class UnknownTokenInURITestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnknownTokenInURI", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/InvalidWsdlElementAttrTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/InvalidWsdlElementAttrTestCase.java index c0f60a848f..4cbe3def2d 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/InvalidWsdlElementAttrTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/InvalidWsdlElementAttrTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class InvalidWsdlElementAttrTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("InvalidWsdlElementAttr", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/MustUseWsdlBindingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/MustUseWsdlBindingTestCase.java index 5a74194796..2fe8af318c 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/MustUseWsdlBindingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/MustUseWsdlBindingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class MustUseWsdlBindingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("MustUseWsdlBinding", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java index 7991de7176..09865ab855 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class WsdlBindingDoesNotMatchTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("WsdlBindingDoesNotMatch", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlPortTypeDoesNotMatchTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlPortTypeDoesNotMatchTestCase.java index 1ef5f7b00a..3be31d5994 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlPortTypeDoesNotMatchTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlPortTypeDoesNotMatchTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor;
import org.apache.tuscany.sca.monitor.Problem;
-import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl;
import domain.CustomCompositeBuilder;
@@ -52,7 +51,7 @@ public class WsdlPortTypeDoesNotMatchTestCase extends TestCase { public void testCalculator() {
Monitor monitor = customDomain.getMonitorInstance();
- Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+ Problem problem = monitor.getLastProblem();
assertNotNull(problem);
assertEquals("WsdlPortTypeDoesNotMatch", problem.getMessageId());
diff --git a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java index a0a7d12b9f..303b8299ad 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class WsdlServiceDoesNotMatchTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("WsdlServiceDoesNotMatch", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java index 555810f453..18809f6af2 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -68,7 +67,7 @@ public class ComponentReferenceTargetNotFoundTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ComponentReferenceTargetNotFound", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateComponentNameTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateComponentNameTestCase.java index 4d70df1102..a7b23ed10f 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateComponentNameTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateComponentNameTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -53,7 +52,7 @@ public class DuplicateComponentNameTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DuplicateComponentName", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java index 7593f39991..83d3064381 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.SCANodeFactory; @@ -56,7 +55,7 @@ public class DuplicateImplementationPropertyNameTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DuplicateImplementationPropertyName", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java index 0a711175dc..5b59a69f86 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.SCANodeFactory; @@ -57,7 +56,7 @@ public class DuplicateImplementationReferenceNameTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DuplicateImplementationReferenceName", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java index 10660795a7..13534d698d 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class DuplicatePropertyNameTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DuplicateComponentPropertyName", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java index 15b4b15989..627e1e975e 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class DuplicateReferenceNameTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("DuplicateComponentReferenceName", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java index 55741ec2ef..2f66235684 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class MultipleBindingsForServiceTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("MultipleBindingsForService", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java index 7f8bd68e5e..48c165ab99 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.SCANodeFactory; @@ -58,7 +57,7 @@ public class NoComponentImplementationTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("NoComponentImplementation", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java index 1f26d3a7d6..35789fbd43 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class NoCompositeNamespaceTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("NoCompositeNamespace", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java index d398efc9ea..94d0e50312 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -64,7 +63,7 @@ public class NoMatchingBindingTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("NoMatchingBinding", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java index 9d2f028dea..afd533bcf4 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class PromotedReferenceNotFoundTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("PromotedReferenceNotFound", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java index 7f836e4b01..6ca4348f26 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class PromotedServiceNotFoundTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("PromotedServiceNotFound", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java index 04c2594cd3..616d2743e2 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class PropertyAttributeMustSupplyNullTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("PropertyMustSupplyNull", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java index 3dabfecbb6..c5b3026322 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class PropertyAttributeTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("PropertyMustSupplyIncompatible", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java index 0dca8ed1df..a096cfd41c 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class PropertyNotFoundTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("PropertyNotFound", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java index 37f7ef352e..4558bc7df3 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class PropertyOverrideManyAttributeTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("PropertyOverrideManyAttribute", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java index ab57283a9e..cff24f6616 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class ReferenceIncompatibleComponentInterfaceTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ReferenceIncompatibleComponentInterface", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java index 4c3cc3856a..c6b4c65235 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class ReferenceIncompatibleInterfaceTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ReferenceIncompatibleInterface", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java index 06fb06f6ad..c4ba0ecbcd 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class ReferenceIncompatibleMultiplicityTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ReferenceIncompatibleMultiplicity", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java index 6bacc8b05e..ab2c373486 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java @@ -18,21 +18,10 @@ */ package calculator.warning; -import java.io.File; - import junit.framework.TestCase; -import org.apache.tuscany.sca.core.ExtensionPointRegistry; -import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; -import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; -import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode; -import org.apache.tuscany.sca.node.SCANodeFactory; -import org.apache.tuscany.sca.node.impl.NodeImpl; import domain.CustomCompositeBuilder; @@ -73,7 +62,7 @@ public class ReferenceNotFoundTestCase extends TestCase { public void testCalculator() throws Exception { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ReferenceNotFound", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java index d615857105..c75d2a0e9d 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class ReferenceWithoutTargetsTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ReferenceWithoutTargets", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java index e9b920119a..1215ddf06a 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; @@ -62,7 +61,7 @@ public class ServiceNotFoundForComponentServiceTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ServiceNotFoundForComponentService", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java index 4d950e30ff..31cf0779b0 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java @@ -27,7 +27,6 @@ import org.apache.tuscany.sca.core.UtilityExtensionPoint; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAContribution; import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.SCANodeFactory; @@ -58,7 +57,7 @@ public class UnresolvedComponentImplementationTestCase extends TestCase { UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class); MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); Monitor monitor = monitorFactory.createMonitor(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnresolvedComponentImplementation", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/contribution/java/AttributePackageMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/contribution/java/AttributePackageMissingTestCase.java index 04135ab2cc..60b0c51fef 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/contribution/java/AttributePackageMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/contribution/java/AttributePackageMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class AttributePackageMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("AttributePackageMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/contribution/namespace/AttributeNameSpaceMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/contribution/namespace/AttributeNameSpaceMissingTestCase.java index ab0afc6f65..dd38802bbe 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/contribution/namespace/AttributeNameSpaceMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/contribution/namespace/AttributeNameSpaceMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class AttributeNameSpaceMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("AttributeNameSpaceMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/contribution/resource/AttributeURIMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/contribution/resource/AttributeURIMissingTestCase.java index 69c4d40bc7..d83a4bfed9 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/contribution/resource/AttributeURIMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/contribution/resource/AttributeURIMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class AttributeURIMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getProblems().get(0); + Problem problem = monitor.getProblems().get(0); assertNotNull(problem); assertEquals("AttributeURIMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/contribution/xml/AttributeCompositeMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/contribution/xml/AttributeCompositeMissingTestCase.java index 32c1a8b3a8..b64de39c80 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/contribution/xml/AttributeCompositeMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/contribution/xml/AttributeCompositeMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class AttributeCompositeMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("AttributeCompositeMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/AttributeUnrecognizedNamespaceTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/AttributeUnrecognizedNamespaceTestCase.java index 9d97e3611a..690fb97a31 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/AttributeUnrecognizedNamespaceTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/AttributeUnrecognizedNamespaceTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class AttributeUnrecognizedNamespaceTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("AttributeUnrecognizedNamespace", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/AttributeWithoutNamespaceTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/AttributeWithoutNamespaceTestCase.java index 80c15dc444..a768535fde 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/AttributeWithoutNamespaceTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/AttributeWithoutNamespaceTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class AttributeWithoutNamespaceTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("AttributeWithoutNamespace", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/BPELProcessNotFoundTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/BPELProcessNotFoundTestCase.java index 81e8aecfeb..64d41bdb48 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/BPELProcessNotFoundTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/BPELProcessNotFoundTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class BPELProcessNotFoundTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("BPELProcessNotFound", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/CannotResolveWSDLReferenceTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/CannotResolveWSDLReferenceTestCase.java index fb0c525aea..585bd62027 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/CannotResolveWSDLReferenceTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/CannotResolveWSDLReferenceTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class CannotResolveWSDLReferenceTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("CannotResolveWSDLReference", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/MyRolePartnerRoleNullTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/MyRolePartnerRoleNullTestCase.java index 445629457e..aab3529fba 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/MyRolePartnerRoleNullTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/MyRolePartnerRoleNullTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class MyRolePartnerRoleNullTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("MyRolePartnerRoleNull", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkHasBothAttrTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkHasBothAttrTestCase.java index 00b904ae65..4c3226f4c8 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkHasBothAttrTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkHasBothAttrTestCase.java @@ -21,7 +21,7 @@ package impl.bpel; import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; +import org.apache.tuscany.sca.monitor.Problem; import domain.CustomCompositeBuilder; @@ -49,10 +49,19 @@ public class PartnerLinkHasBothAttrTestCase extends TestCase { //nothing to do } + private static boolean isMessageLogged(Monitor monitor, String messageId) { + for (Problem problem : monitor.getProblems()){ + if (problem.getMessageId().equals(messageId)){ + return true; + } + } + return false; + } + public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - assertTrue(((DefaultLoggingMonitorImpl)monitor).isMessageLogged("PartnerLinkHasBothAttr")); - /*Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + assertTrue(isMessageLogged(monitor, "PartnerLinkHasBothAttr")); + /*Problem problem = monitor.getLastLoggedProblem(); assertNotNull(problem); assertEquals("PartnerLinkHasBothAttr", problem.getMessageId());*/ } diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkNoMatchingTypeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkNoMatchingTypeTestCase.java index b7a4ee6fef..b9c0b68f7e 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkNoMatchingTypeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkNoMatchingTypeTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class PartnerLinkNoMatchingTypeTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("PartnerLinkNoMatchingType", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkTypeNoRolesTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkTypeNoRolesTestCase.java index 32d3211f36..fc32e96b52 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkTypeNoRolesTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/bpel/PartnerLinkTypeNoRolesTestCase.java @@ -21,7 +21,7 @@ package impl.bpel; import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; +import org.apache.tuscany.sca.monitor.Problem; import domain.CustomCompositeBuilder; @@ -49,10 +49,19 @@ public class PartnerLinkTypeNoRolesTestCase extends TestCase { //nothing to do } + private static boolean isMessageLogged(Monitor monitor, String messageId) { + for (Problem problem : monitor.getProblems()){ + if (problem.getMessageId().equals(messageId)){ + return true; + } + } + return false; + } + public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - assertTrue(((DefaultLoggingMonitorImpl)monitor).isMessageLogged("PartnerLinkTypeNoRoles")); - /*Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + assertTrue(isMessageLogged(monitor, "PartnerLinkTypeNoRoles")); + /*Problem problem = monitor.getLastLoggedProblem(); assertNotNull(problem); assertEquals("PartnerLinkTypeNoRoles", problem.getMessageId());*/ diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/ejb/EJBLinkAttributeMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/ejb/EJBLinkAttributeMissingTestCase.java index b31451c433..4b367f85ef 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/ejb/EJBLinkAttributeMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/ejb/EJBLinkAttributeMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class EJBLinkAttributeMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("EJBLinkAttributeMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/java/ClassNotFoundExceptionTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/java/ClassNotFoundExceptionTestCase.java index 3a7745722a..969690acaf 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/java/ClassNotFoundExceptionTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/java/ClassNotFoundExceptionTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class ClassNotFoundExceptionTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ClassNotFoundException", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java index 59fc3ce79c..eef964e274 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class ContributionResolveExceptionTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/resource/CouldNotResolveLocationTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/resource/CouldNotResolveLocationTestCase.java index 14ba8e992e..c2fd7b3410 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/resource/CouldNotResolveLocationTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/resource/CouldNotResolveLocationTestCase.java @@ -23,7 +23,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -51,7 +50,7 @@ public class CouldNotResolveLocationTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); Assert.assertNotNull(problem); Assert.assertEquals("CouldNotResolveLocation", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/resource/LocationAttributeMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/resource/LocationAttributeMissingTestCase.java index 461895f824..c6a58d2b88 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/resource/LocationAttributeMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/resource/LocationAttributeMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class LocationAttributeMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("LocationAttributeMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java index 9b7dbef3dd..ff0b2f3589 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java @@ -21,7 +21,7 @@ package impl.spring; import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; +import org.apache.tuscany.sca.monitor.Problem; import domain.CustomCompositeBuilder; @@ -48,10 +48,19 @@ public class ContributionResolveExceptionTestCase extends TestCase { protected void tearDown() throws Exception { //node.stop(); } + + private static boolean isMessageLogged(Monitor monitor, String messageId) { + for (Problem problem : monitor.getProblems()){ + if (problem.getMessageId().equals(messageId)){ + return true; + } + } + return false; + } public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - assertTrue(((DefaultLoggingMonitorImpl)monitor).isMessageLogged("ContributionResolveException")); + assertTrue(isMessageLogged(monitor, "ContributionResolveException")); //assertEquals("ContributionResolveException", problem.getMessageId()); } } diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java index cd38b53f66..7b445960f1 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class LocationAttributeMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("LocationAttributeMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java index 83550ae58d..6b4521cdc9 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class UnableToResolveComponentTypeTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); //assertNotNull(problem); //assertEquals("UnableToResolveComponentType", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/widget/CouldNotResolveLocationTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/widget/CouldNotResolveLocationTestCase.java index d098bb4bf8..f46e9e4035 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/widget/CouldNotResolveLocationTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/widget/CouldNotResolveLocationTestCase.java @@ -23,7 +23,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -51,7 +50,7 @@ public class CouldNotResolveLocationTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); Assert.assertNotNull(problem); Assert.assertEquals("CouldNotResolveLocation", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/widget/LocationAttributeMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/widget/LocationAttributeMissingTestCase.java index 2f85d8ed4a..ed95bcdcf0 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/widget/LocationAttributeMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/widget/LocationAttributeMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class LocationAttributeMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("LocationAttributeMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java index f90fc3b83f..bd5a6d9601 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class CouldNotLocateFileTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("CouldNotLocateFile", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java index 01450a8836..390eeb7e95 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class LocationAttributeMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("LocationAttributeMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java index a03e056298..e2bee4d2ac 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class ClassNotFoundTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ClassNotFoundException", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java index e0524f57b7..3b567da717 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class ContributionResolveExceptionTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); //assertNotNull(problem); //assertEquals("ContributionResolveException", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java index e212477c61..fc03bc25eb 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class InvalidWSDLInterfaceAttrTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("InvalidWSDLInterfaceAttr", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java index df2a2671df..d41d72585f 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class WsdlInterfaceDoesNotMatchTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("WsdlInterfaceDoesNotMatch", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/AlwaysProvidedIntentNotFoundTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/AlwaysProvidedIntentNotFoundTestCase.java index 361e2f2bfb..2d4bb3d499 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/AlwaysProvidedIntentNotFoundTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/AlwaysProvidedIntentNotFoundTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class AlwaysProvidedIntentNotFoundTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("AlwaysProvidedIntentNotFound", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/ErrorInPolicyIntentDefinitionTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/ErrorInPolicyIntentDefinitionTestCase.java index a85dc334f4..5b5bfe7b37 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/ErrorInPolicyIntentDefinitionTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/ErrorInPolicyIntentDefinitionTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class ErrorInPolicyIntentDefinitionTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("ErrorInPolicyIntentDefinition", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/IntentNotSpecifiedTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/IntentNotSpecifiedTestCase.java index 3f98757ce5..8ef3cacc4e 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/IntentNotSpecifiedTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/IntentNotSpecifiedTestCase.java @@ -21,7 +21,7 @@ package policy.xml; import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; +import org.apache.tuscany.sca.monitor.Problem; import domain.CustomCompositeBuilder; @@ -49,10 +49,19 @@ public class IntentNotSpecifiedTestCase extends TestCase { //node.stop(); } + private static boolean isMessageLogged(Monitor monitor, String messageId) { + for (Problem problem : monitor.getProblems()){ + if (problem.getMessageId().equals(messageId)){ + return true; + } + } + return false; + } + public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - assertTrue(((DefaultLoggingMonitorImpl)monitor).isMessageLogged("IntentNotSpecified")); - /*Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + assertTrue(isMessageLogged(monitor, "IntentNotSpecified")); + /*Problem problem = monitor.getLastLoggedProblem(); assertNotNull(problem); assertEquals("IntentNotSpecified", problem.getMessageId());*/ } diff --git a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/MayProvideIntentNotFoundTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/MayProvideIntentNotFoundTestCase.java index 3b8d075165..38d59196dd 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/MayProvideIntentNotFoundTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/MayProvideIntentNotFoundTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class MayProvideIntentNotFoundTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("MayProvideIntentNotFound", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/RequiredAttributeMissingTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/RequiredAttributeMissingTestCase.java index bcf1f82392..9671f9c983 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/RequiredAttributeMissingTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/RequiredAttributeMissingTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class RequiredAttributeMissingTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("RequiredAttributeMissing", problem.getMessageId()); diff --git a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/UnableToMapPoliciesTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/UnableToMapPoliciesTestCase.java index 5683d54e64..b3ccb8b278 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/UnableToMapPoliciesTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/UnableToMapPoliciesTestCase.java @@ -20,8 +20,6 @@ package policy.xml; import junit.framework.TestCase; -import org.apache.tuscany.sca.monitor.Monitor; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.junit.Ignore; import domain.CustomCompositeBuilder; @@ -56,9 +54,9 @@ public class UnableToMapPoliciesTestCase extends TestCase { //elements... /* Monitor monitor = customDomain.getMonitorInstance(); - assertTrue(((DefaultLoggingMonitorImpl)monitor).isMessageLogged("UnableToMapPolicies")); + assertTrue(monitor.isMessageLogged("UnableToMapPolicies")); */ - /*Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + /*Problem problem = monitor.getLastLoggedProblem(); assertNotNull(problem); assertEquals("UnableToMapPolicies", problem.getMessageId());*/ } diff --git a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/UnrecognizedIntentAttachPointTypeTestCase.java b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/UnrecognizedIntentAttachPointTypeTestCase.java index eec39d711e..08c27ee011 100644 --- a/branches/sca-equinox/itest/validation/src/test/java/policy/xml/UnrecognizedIntentAttachPointTypeTestCase.java +++ b/branches/sca-equinox/itest/validation/src/test/java/policy/xml/UnrecognizedIntentAttachPointTypeTestCase.java @@ -22,7 +22,6 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.Problem; -import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import domain.CustomCompositeBuilder; @@ -52,7 +51,7 @@ public class UnrecognizedIntentAttachPointTypeTestCase extends TestCase { public void testCalculator() { Monitor monitor = customDomain.getMonitorInstance(); - Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem(); + Problem problem = monitor.getLastProblem(); assertNotNull(problem); assertEquals("UnrecognizedIntentAttachPointType", problem.getMessageId()); |