diff options
author | dims <dims@13f79535-47bb-0310-9956-ffa450edef68> | 2008-06-17 00:23:01 +0000 |
---|---|---|
committer | dims <dims@13f79535-47bb-0310-9956-ffa450edef68> | 2008-06-17 00:23:01 +0000 |
commit | bdd0a41aed7edf21ec2a65cfa17a86af2ef8c48a (patch) | |
tree | 38a92061c0793434c4be189f1d70c3458b6bc41d /sandbox/bdaniel/propertyTest/src/test/java/testing/PropertyITest.java |
Move Tuscany from Incubator to top level.
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@668359 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sandbox/bdaniel/propertyTest/src/test/java/testing/PropertyITest.java')
-rw-r--r-- | sandbox/bdaniel/propertyTest/src/test/java/testing/PropertyITest.java | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/sandbox/bdaniel/propertyTest/src/test/java/testing/PropertyITest.java b/sandbox/bdaniel/propertyTest/src/test/java/testing/PropertyITest.java new file mode 100644 index 0000000000..79e58229a7 --- /dev/null +++ b/sandbox/bdaniel/propertyTest/src/test/java/testing/PropertyITest.java @@ -0,0 +1,76 @@ +package testing;
+
+import junit.framework.TestCase;
+
+import org.osoa.sca.CurrentCompositeContext;
+
+public class PropertyITest extends TestCase {
+ private ABComponent abService;
+ private CDComponent cdService;
+ private ABCDComponent abcdService;
+ // private PropertyService propertyService;
+
+
+ public void testA() {
+ assertEquals("a", abService.getA());
+ }
+
+ public void testB() {
+ assertEquals("b", abService.getB());
+ }
+
+ public void testC() {
+ assertEquals("c", cdService.getC());
+ }
+
+ public void testC2() {
+ assertEquals("c", cdService.getC2());
+ }
+ public void testD() {
+ assertEquals("d", cdService.getD());
+ }
+
+ public void testF() {
+ assertEquals("a", abService.getF());
+ }
+
+ public void testZ() {
+ assertEquals("z", abService.getZ());
+ }
+
+
+ public void testIntValue() {
+ assertEquals(1, abService.getIntValue());
+ }
+
+ public void testDefaultValue() {
+ assertEquals(1, abService.getIntValue());
+ }
+
+ public void testDefaultValueOverride() {
+ assertEquals(1, cdService.getOverrideValue());
+ }
+
+ public void testNoSource() {
+ assertEquals("aValue", cdService.getNoSource());
+ }
+
+ public void testFileProperty() {
+ assertEquals("fileValue", cdService.getFileProperty());
+ }
+
+ public void testABCD() {
+ assertEquals("a", abcdService.getA());
+ assertEquals("b", abcdService.getB());
+ assertEquals("c", abcdService.getC());
+ assertEquals("d", abcdService.getD());
+ }
+
+ protected void setUp() throws Exception {
+ super.setUp();
+ abService = CurrentCompositeContext.getContext().locateService(ABComponent.class, "ABComponent");
+ cdService = CurrentCompositeContext.getContext().locateService(CDComponent.class, "CDComponent");
+ abcdService = CurrentCompositeContext.getContext().locateService(ABCDComponent.class, "ABCDComponent");
+ // propertyService = CurrentCompositeContext.getContext().locateService(PropertyService.class, "PropertyService");
+ }
+}
|