diff options
author | rfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68> | 2009-02-20 20:10:37 +0000 |
---|---|---|
committer | rfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68> | 2009-02-20 20:10:37 +0000 |
commit | 3a8a64103bcc4891fb1a1f4cc4538f9d5b62a7ba (patch) | |
tree | ccd8919c277ad88c032acb3167fdd4645586cb07 /java/sca/modules/implementation-java/src/test | |
parent | 7b9fa54dced70baffa6578b0be902b06092584a7 (diff) |
Start to implement the SCA policy framework 1.1 spec draft from OASIS OpenCSA
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@746356 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/sca/modules/implementation-java/src/test')
-rw-r--r-- | java/sca/modules/implementation-java/src/test/java/org/apache/tuscany/sca/implementation/java/introspect/impl/PolicyProcessorTestCase.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/java/sca/modules/implementation-java/src/test/java/org/apache/tuscany/sca/implementation/java/introspect/impl/PolicyProcessorTestCase.java b/java/sca/modules/implementation-java/src/test/java/org/apache/tuscany/sca/implementation/java/introspect/impl/PolicyProcessorTestCase.java index e6a29b0e13..6c9ffc7975 100644 --- a/java/sca/modules/implementation-java/src/test/java/org/apache/tuscany/sca/implementation/java/introspect/impl/PolicyProcessorTestCase.java +++ b/java/sca/modules/implementation-java/src/test/java/org/apache/tuscany/sca/implementation/java/introspect/impl/PolicyProcessorTestCase.java @@ -26,9 +26,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; -import org.apache.tuscany.sca.assembly.ConfiguredOperation; import org.apache.tuscany.sca.assembly.DefaultAssemblyFactory; -import org.apache.tuscany.sca.assembly.OperationsConfigurator; import org.apache.tuscany.sca.implementation.java.DefaultJavaImplementationFactory; import org.apache.tuscany.sca.implementation.java.JavaImplementation; import org.apache.tuscany.sca.implementation.java.JavaImplementationFactory; @@ -37,7 +35,7 @@ import org.apache.tuscany.sca.interfacedef.java.JavaInterface; import org.apache.tuscany.sca.interfacedef.java.impl.PolicyJavaInterfaceVisitor; import org.apache.tuscany.sca.policy.DefaultPolicyFactory; import org.apache.tuscany.sca.policy.Intent; -import org.apache.tuscany.sca.policy.PolicySetAttachPoint; +import org.apache.tuscany.sca.policy.PolicySubject; import org.junit.Before; import org.junit.Test; import org.oasisopen.sca.annotation.Requires; @@ -102,13 +100,13 @@ public class PolicyProcessorTestCase { } private void verifyIntents(Class<?> serviceImplClass, JavaImplementation type) { - if ( !(type instanceof PolicySetAttachPoint) ) { + if ( !(type instanceof PolicySubject) ) { fail("No Intents on the service "); } Requires serviceImplIntentAnnotation = (Requires)serviceImplClass.getAnnotation(Requires.class); if (serviceImplIntentAnnotation != null) { String[] serviceImplIntents = serviceImplIntentAnnotation.value(); - List<Intent> requiredIntents = ((PolicySetAttachPoint)type).getRequiredIntents(); + List<Intent> requiredIntents = ((PolicySubject)type).getRequiredIntents(); if (serviceImplIntents.length > 0) { if (requiredIntents == null || requiredIntents.size() == 0) { fail("No Intents on the service "); @@ -162,6 +160,7 @@ public class PolicyProcessorTestCase { } } + /* for (Method method : interfaceClass.getDeclaredMethods()) { Requires methodIntentAnnotation = method.getAnnotation(Requires.class); @@ -232,6 +231,7 @@ public class PolicyProcessorTestCase { } } } + */ } } |