You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by ke...@apache.org on 2007/04/24 16:38:08 UTC

svn commit: r531958 - in /incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests: CTSGeneralSuite.java xsd/XSDComplexTypeTest.java

Author: kelvingoodson
Date: Tue Apr 24 07:38:07 2007
New Revision: 531958

URL: http://svn.apache.org/viewvc?view=rev&rev=531958
Log:
TUSCANY-1224 

Modified:
    incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/CTSGeneralSuite.java
    incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/xsd/XSDComplexTypeTest.java

Modified: incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/CTSGeneralSuite.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/CTSGeneralSuite.java?view=diff&rev=531958&r1=531957&r2=531958
==============================================================================
--- incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/CTSGeneralSuite.java (original)
+++ incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/CTSGeneralSuite.java Tue Apr 24 07:38:07 2007
@@ -27,6 +27,7 @@
 import test.sdo21.tests.conversion.DateConversionTest;
 import test.sdo21.tests.general.XSDHelperTest;
 import test.sdo21.tests.xsd.XSDChoiceTest;
+import test.sdo21.tests.xsd.XSDComplexTypeTest;
 import test.sdo21.tests.api.DynamicTypesFromSchemaTestCase;
 
 /**
@@ -43,7 +44,7 @@
  */
 @RunWith(Suite.class)
 @Suite.SuiteClasses( {DateConversionTest.class, XSDHelperTest.class, DataObjectTest.class,
-                      DynamicTypesFromSchemaTestCase.class, XSDChoiceTest.class})
+                      DynamicTypesFromSchemaTestCase.class, XSDChoiceTest.class, XSDComplexTypeTest.class})
 public class CTSGeneralSuite {
 
 }

Modified: incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/xsd/XSDComplexTypeTest.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/xsd/XSDComplexTypeTest.java?view=diff&rev=531958&r1=531957&r2=531958
==============================================================================
--- incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/xsd/XSDComplexTypeTest.java (original)
+++ incubator/tuscany/java/cts/sdo2.1/src/main/java/test/sdo21/tests/xsd/XSDComplexTypeTest.java Tue Apr 24 07:38:07 2007
@@ -46,17 +46,15 @@
     // parse the schema
     List types = define("/complexType/cT_01.xsd");
 
-    assertEquals(1, types.size());
-
     Type type = (Type) types.get(0);
-    assertTrue(type.isSequenced());
+    assertFalse(type.isSequenced());
     assertFalse(type.isOpen());
     assertFalse(type.isDataType());
     assertFalse(type.isAbstract());
     assertEquals("cT_01", type.getName());
 
-    assertPropertyExists(type, "id", "Int", true, false);
-    assertPropertyExists(type, "name", "String", true, false);
+    assertPropertyExists(type, "id", "Int", false, false);
+    assertPropertyExists(type, "name", "String", false, false);
   }
 
   /**
@@ -67,16 +65,15 @@
   @Test public void testTC129ComplexTypeAbstractTrue() throws Exception {
 
     List types = define("/complexType/cT_02.xsd");
-    assertEquals(1, types.size());
 
     Type type = (Type) types.get(0);
-    assertTrue(type.isSequenced());
+    assertFalse(type.isSequenced());
     assertEquals("cT_02", type.getName());
     assertTrue(type.isAbstract());
 
-    assertPropertyExists(type, "id", "Int", true, false);
+    assertPropertyExists(type, "id", "Int", false, false);
     assertFalse(type.getProperty("id").isReadOnly() );
-    assertPropertyExists(type, "name", "String", true, false);
+    assertPropertyExists(type, "name", "String", false, false);
     assertFalse(type.getProperty("name").isReadOnly() );
   }
 
@@ -174,15 +171,14 @@
    */
   @Test public void testTC132ComplexTypeGroupWithSequence() throws Exception {
     List types = define("/complexType/cT_05.xsd");
-    assertEquals(1, types.size());
 
     Type type = (Type) types.get(0);
     assertEquals("cT_05", type.getName());
     assertFalse(type.isAbstract());
 
-    assertPropertyExists(type, "id", "Int", true, false);
+    assertPropertyExists(type, "id", "Int", false, false);
     assertFalse(type.getProperty("id").isReadOnly());
-    assertPropertyExists(type, "name", "String", true, false);
+    assertPropertyExists(type, "name", "String", false, false);
     assertFalse(type.getProperty("name").isReadOnly());
   }
 
@@ -193,7 +189,6 @@
    */
   @Test public void testTC133ComplexTypeAnonymous() throws Exception {
     List types = define("/complexType/cT_06.xsd");
-    assertEquals(1, types.size());
 
     // The spec maps the name of anonymous types to the name
     // of their enclosing element. This is a broken method however,
@@ -206,11 +201,11 @@
                                                          "cT_06" );
     Type type = property.getType();
     assertFalse(type.isAbstract());
-    assertTrue(type.isSequenced());
+    assertFalse(type.isSequenced());
 
-    assertPropertyExists(type, "id", "Int", true, false);
+    assertPropertyExists(type, "id", "Int", false, false);
     assertFalse(type.getProperty("id").isReadOnly());
-    assertPropertyExists(type, "name", "String", true, false);
+    assertPropertyExists(type, "name", "String", false, false);
     assertFalse(type.getProperty("name").isReadOnly());
   }
 
@@ -221,16 +216,15 @@
    */
   @Test public void testTC134ComplexTypeNamed() throws Exception {
     List types = define("/complexType/cT_07.xsd");
-    assertEquals(1, types.size());
 
     Type type = (Type) types.get(0);
     assertEquals("cT_07", type.getName());
     assertFalse(type.isAbstract());
-    assertTrue(type.isSequenced());
+    assertFalse(type.isSequenced());
 
-    assertPropertyExists(type, "id", "Int", true, false);
+    assertPropertyExists(type, "id", "Int", false, false);
     assertFalse(type.getProperty("id").isReadOnly());
-    assertPropertyExists(type, "name", "String", true, false);
+    assertPropertyExists(type, "name", "String", false, false);
     assertFalse(type.getProperty("name").isReadOnly());
   }
 
@@ -351,7 +345,6 @@
    */
   @Test public void testTC143ComplexTypeSimpleContent() throws Exception {
     List types = define("/complexType/cT_18.xsd");
-    assertEquals(1, types.size());
 
     Type type = typeHelper.getType("http://www.example.com/xsd/18/", "cT_18");
 
@@ -398,7 +391,6 @@
    */
   @Test public void test_cT_19() throws Exception {
     List types = define("/complexType/cT_19.xsd");
-    assertEquals(1, types.size());
 
     // parent
     Type type = getType(types, "cT_19");
@@ -418,9 +410,7 @@
     List properties = type.getDeclaredProperties();
     assertEquals(2, properties.size());
 
-    Property p1 = (Property) properties.get(0);
-
-    assertEquals("lang", p1.getName());
+    Property p1 = type.getProperty( "lang" );
     assertEquals("String", p1.getType().getName());
 
     // however complex types with simple content get a special
@@ -453,8 +443,7 @@
    * @throws Exception
    */
   @Test public void test_cT_22() throws Exception {
-    List types = define("/complexType/cT_22.xsd3");
-    assertEquals(1, types.size());
+    List types = define("/complexType/cT_22.xsd");
 
     Type type = getType(types, "cT_22");
     assertFalse(type.isSequenced());
@@ -474,9 +463,7 @@
     List properties = type.getDeclaredProperties();
     assertEquals(2, properties.size());
 
-    Property p1 = (Property) properties.get(0);
-
-    assertEquals("lang", p1.getName());
+    Property p1 = type.getProperty( "lang" );
     assertEquals("String", p1.getType().getName());
 
     // however complex types with simple content get a special
@@ -532,9 +519,8 @@
     List properties = type.getDeclaredProperties();
     assertEquals(2, properties.size());
 
-    Property p1 = (Property) properties.get(0);
-
-    assertEquals("lang", p1.getName());
+    Property p1 = type.getProperty( "lang" );
+    assertNotNull( p1 );
 
     // the actual type here for the lang attribute will be
     // the anonymous simple type, which as it's base will
@@ -574,7 +560,7 @@
   @Test public void testTC300ComplexTypeContainingAllGroupWithElements() throws Exception {
     List types = define("/complexType/cT_24.xsd");
     Type type = getType(types, "cT_24");
-    assertPropertyExists(type, "p1", "String", true, false);
+    assertPropertyExists(type, "p1", "String", false, false);
   }
 
   /**
@@ -585,7 +571,7 @@
   @Test public void test_cT_25() throws Exception {
     List types = define("/complexType/cT_25.xsd");
     Type type = getType(types, "cT_25");
-    assertPropertyExists(type, "p1", "String", true, false);
+    assertPropertyExists(type, "p1", "String", false, false);
   }
 
   /**
@@ -596,7 +582,7 @@
   @Test public void test_cT_26() throws Exception {
     List types = define("/complexType/cT_26.xsd");
     Type type = getType(types, "cT_26");
-    assertPropertyExists(type, "p1", "String", true, true);
+    assertPropertyExists(type, "p1", "String", false, true);
   }
 
   /**
@@ -607,7 +593,7 @@
   @Test public void testTC299ComplexTypeContainingUnboundedElement() throws Exception {
     List types = define("/complexType/cT_27.xsd");
     Type type = typeHelper.getType("http://www.example.com/xsd/27/", "cT_27");
-    assertPropertyExists(type, "p1", "String", true, true);
+    assertPropertyExists(type, "p1", "String", false, true);
   }
 
   /**
@@ -617,54 +603,54 @@
    */
   @Test public void testTC297ComplexTypeContainingElementsOfAllTypes() throws Exception {
     List types = define("/complexType/cT_28.xsd");
-    assertEquals(1, types.size());
 
     Type type = getType(types, "cT_28");
-    assertTrue(type.isSequenced());
+    assertFalse(type.isSequenced());
     assertEquals( 44, type.getProperties().size() );
-    assertPropertyExists(type, "type_date", "YearMonthDay", true, false);
-    assertPropertyExists(type, "type_dateTime", "DateTime", true, false);
-    assertPropertyExists(type, "type_decimal", "Decimal", true, false);
-    assertPropertyExists(type, "type_double", "Double", true, false);
-    assertPropertyExists(type, "type_duration", "Duration", true, false);
-    assertPropertyExists(type, "type_float", "Float", true, false);
-    assertPropertyExists(type, "type_gDay", "Day", true, false);
-    assertPropertyExists(type, "type_gMonth", "Month", true, false);
-    assertPropertyExists(type, "type_gMonthDay", "MonthDay", true, false);
-    assertPropertyExists(type, "type_gYear", "Year", true, false);
-    assertPropertyExists(type, "type_gYearMonth", "YearMonth", true, false);
-    assertPropertyExists(type, "type_int", "Int", true, false);
-    assertPropertyExists(type, "type_integer", "Integer", true, false);
-    assertPropertyExists(type, "type_long", "Long", true, false);
-    assertPropertyExists(type, "type_negativeInteger", "Integer", true, false);
-    assertPropertyExists(type, "type_nonNegativeInteger", "Integer", true, false);
-    assertPropertyExists(type, "type_nonPositiveInteger", "Integer", true, false);
-    assertPropertyExists(type, "type_positiveInteger", "Integer", true, false);
-    assertPropertyExists(type, "type_short", "Short", true, false);
-    assertPropertyExists(type, "type_string", "String", true, false);
-    assertPropertyExists(type, "type_time", "Time", true, false);
-    assertPropertyExists(type, "type_unsignedByte", "Short", true, false);
-    assertPropertyExists(type, "type_unsignedInt", "Long", true, false);
-    assertPropertyExists(type, "type_unsignedLong", "Integer", true, false);
-    assertPropertyExists(type, "type_unsignedShort", "Int", true, false);
+    assertPropertyExists(type, "type_date", "YearMonthDay", false, false);
+    assertPropertyExists(type, "type_dateTime", "DateTime", false, false);
+    assertPropertyExists(type, "type_decimal", "Decimal", false, false);
+    assertPropertyExists(type, "type_double", "Double", false, false);
+    assertPropertyExists(type, "type_duration", "Duration", false, false);
+    assertPropertyExists(type, "type_float", "Float", false, false);
+    assertPropertyExists(type, "type_gDay", "Day", false, false);
+    assertPropertyExists(type, "type_gMonth", "Month", false, false);
+    assertPropertyExists(type, "type_gMonthDay", "MonthDay", false, false);
+    assertPropertyExists(type, "type_gYear", "Year", false, false);
+    assertPropertyExists(type, "type_gYearMonth", "YearMonth", false, false);
+    assertPropertyExists(type, "type_int", "Int", false, false);
+    assertPropertyExists(type, "type_integer", "Integer", false, false);
+    assertPropertyExists(type, "type_long", "Long", false, false);
+    assertPropertyExists(type, "type_negativeInteger", "Integer", false, false);
+    assertPropertyExists(type, "type_nonNegativeInteger", "Integer", false, false);
+    assertPropertyExists(type, "type_nonPositiveInteger", "Integer", false, false);
+    assertPropertyExists(type, "type_positiveInteger", "Integer", false, false);
+    assertPropertyExists(type, "type_short", "Short", false, false);
+    assertPropertyExists(type, "type_string", "String", false, false);
+    assertPropertyExists(type, "type_time", "Time", false, false);
+    assertPropertyExists(type, "type_unsignedByte", "Short", false, false);
+    assertPropertyExists(type, "type_unsignedInt", "Long", false, false);
+    assertPropertyExists(type, "type_unsignedLong", "Integer", false, false);
+    assertPropertyExists(type, "type_unsignedShort", "Int", false, false);
     assertPropertyExists(type, "type_anyType", "DataObject", true, false);
-    assertPropertyExists(type, "type_anyURI", "URI", true, false);
-    assertPropertyExists(type, "type_base64Binary", "Bytes", true, false);
-    assertPropertyExists(type, "type_byte", "Byte", true, false);
-    assertPropertyExists(type, "type_ENTITY", "String", true, false);
-    assertPropertyExists(type, "type_hexBinary", "Bytes", true, false);
-    assertPropertyExists(type, "type_ID", "String", true, false);
-    assertPropertyExists(type, "type_IDREF", "String", true, false);
-    assertPropertyExists(type, "type_language", "String", true, false);
-    assertPropertyExists(type, "type_Name", "String", true, false);
-    assertPropertyExists(type, "type_NCName", "String", true, false);
-    assertPropertyExists(type, "type_QName", "URI", true, false);
-    assertPropertyExists(type, "type_token", "String", true, false);
-    assertPropertyExists(type, "type_NMTOKEN", "String", true, false);
-    assertPropertyExists(type, "type_NMTOKENS", "Strings", true, false);
-    assertPropertyExists(type, "type_IDREFS", "Strings", true, false);
-    assertPropertyExists(type, "type_ENTITIES", "Strings", true, false);
-    assertPropertyExists(type, "type_anySimpleType", "Object", true, false);
+    assertPropertyExists(type, "type_anyURI", "URI", false, false);
+    //    assertion removed pending resolution of spec issue SDO-128
+    //    assertPropertyExists(type, "type_base64Binary", "Bytes", false, false);
+    assertPropertyExists(type, "type_byte", "Byte", false, false);
+    assertPropertyExists(type, "type_ENTITY", "String", false, false);
+    assertPropertyExists(type, "type_hexBinary", "Bytes", false, false);
+    assertPropertyExists(type, "type_ID", "String", false, false);
+    assertPropertyExists(type, "type_IDREF", "String", false, false);
+    assertPropertyExists(type, "type_language", "String", false, false);
+    assertPropertyExists(type, "type_Name", "String", false, false);
+    assertPropertyExists(type, "type_NCName", "String", false, false);
+    assertPropertyExists(type, "type_QName", "URI", false, false);
+    assertPropertyExists(type, "type_token", "String", false, false);
+    assertPropertyExists(type, "type_NMTOKEN", "String", false, false);
+    assertPropertyExists(type, "type_NMTOKENS", "Strings", false, false);
+    assertPropertyExists(type, "type_IDREFS", "Strings", false, false);
+    assertPropertyExists(type, "type_ENTITIES", "Strings", false, false);
+    assertPropertyExists(type, "type_anySimpleType", "Object", false, false);
   }
 
   /**
@@ -674,7 +660,6 @@
    */
   @Test public void test_cT_29() throws Exception {
     List types = define("/complexType/cT_29.xsd");
-    assertEquals(1, types.size());
 
     Type type = getType(types, "cT_29");
     assertFalse(type.isSequenced());
@@ -704,7 +689,8 @@
     assertPropertyExists(type, "type_unsignedLong", "Integer", false, false);
     assertPropertyExists(type, "type_unsignedShort", "Int", false, false);
     assertPropertyExists(type, "type_anyURI", "URI", false, false);
-    assertPropertyExists(type, "type_base64Binary", "Bytes", false, false);
+    //    assertion removed pending resolution of spec issue SDO-128
+    //    assertPropertyExists(type, "type_base64Binary", "Bytes", false, false);
     assertPropertyExists(type, "type_byte", "Byte", false, false);
     assertPropertyExists(type, "type_ENTITIES", "Strings", false, false);
     assertPropertyExists(type, "type_ENTITY", "String", false, false);
@@ -730,13 +716,12 @@
    */
   @Test public void test_cT_30() throws Exception {
     List types = define("/complexType/cT_30.xsd");
-    assertEquals(1, types.size());
 
     Type type = getType(types, "cT_30");
-    assertTrue(type.isSequenced());
-    assertPropertyExists(type, "p1", "String", true, false);
-    assertPropertyExists(type, "p2", "String", true, false);
-    assertPropertyExists(type, "p3", "Int", true, false);
+    assertFalse(type.isSequenced());
+    assertPropertyExists(type, "p1", "String", false, false);
+    assertPropertyExists(type, "p2", "String", false, false);
+    assertPropertyExists(type, "p3", "Int", false, false);
   }
 
   /**
@@ -750,12 +735,12 @@
     assertEquals(2, types.size());
 
     Type type = getType(types, "cT_31");
-    assertTrue(type.isSequenced());
-    assertPropertyExists(type, "p1", "String", true, false);
-    assertPropertyExists(type, "p2", "String", true, false);
-    assertPropertyExists(type, "p3", "Int", true, false);
-    assertPropertyExists(type, "p4", "String", true, false);
-    assertPropertyExists(type, "p5", "String", true, false);
+    assertFalse(type.isSequenced());
+    assertPropertyExists(type, "p1", "String", false, false);
+    assertPropertyExists(type, "p2", "String", false, false);
+    assertPropertyExists(type, "p3", "Int", false, false);
+    assertPropertyExists(type, "p4", "String", false, false);
+    assertPropertyExists(type, "p5", "String", false, false);
   }
 
   /**
@@ -765,12 +750,11 @@
    */
   @Test public void test_cT_42() throws Exception {
     List types = define("/complexType/cT_42.xsd");
-    assertEquals(1, types.size());
 
     Type type = getType(types, "cT_42");
     assertTrue(type.isSequenced());
-    assertPropertyExists(type, "id", "Int", true, false);
-    assertPropertyExists(type, "name", "String", true, false);
+    assertPropertyExists(type, "id", "Int", false, false);
+    assertPropertyExists(type, "name", "String", false, false);
   }
 
 
@@ -782,11 +766,9 @@
    */
   @Test public void test_cT_43() throws Exception {
     List types = define("/complexType/cT_43.xsd");
-    assertEquals(1, types.size());
 
     Type type = getType(types, "cT_43");
     assertTrue(type.isOpen());
-    assertTrue(type.isSequenced());
     assertEquals(0, type.getProperties().size());
   }
 
@@ -798,7 +780,6 @@
    */
   @Test public void test_cT_44() throws Exception {
     List types = define("/complexType/cT_44.xsd");
-    assertEquals(1, types.size());
 
     Type type = getType(types, "cT_44");
     assertTrue(type.isOpen());
@@ -814,7 +795,6 @@
    */
   @Test public void test_cT_45() throws Exception {
     List types = define("/complexType/cT_45.xsd");
-    assertEquals(1, types.size());
 
     Type type = getType(types, "cT_45");
     assertTrue(type.isOpen());
@@ -830,17 +810,16 @@
   @Test public void test_cT_46() throws Exception {
 
     List types = define("/complexType/cT_46.xsd");
-    assertEquals(1, types.size());
 
     Type type = (Type) types.get(0);
-    assertTrue(type.isSequenced());
+    assertFalse(type.isSequenced());
     assertFalse(type.isOpen());
     assertFalse(type.isDataType());
     assertFalse(type.isAbstract());
     assertEquals("cT_46", type.getName());
 
-    assertPropertyExists(type, "id", "Int", true, false);
-    assertPropertyExists(type, "name", "String", true, false);
+    assertPropertyExists(type, "id", "Int", false, false);
+    assertPropertyExists(type, "name", "String", false, false);
 
     assertEquals( false, type.getProperty("id").isNullable() );
     assertEquals( true, type.getProperty("name").isNullable() );
@@ -854,8 +833,6 @@
   @Test public void testTC298ComplexTypeSetAnySimpleTypeWithStringValue() throws Exception {
     List types = define("/complexType/cT_47.xsd");
 
-    assertEquals(1, types.size());
-
     DataObject dobj = testHelper.getDataFactory().create( "http://www.example.com/xsd/47/", "cT_47" );
     Property p = dobj.getProperty( "type_anySimpleType" );
     assertNotNull( p );
@@ -885,81 +862,6 @@
     String typeName1 = p1.getType().getName();
     String typeName2 = p2.getType().getName();
     assertFalse( typeName1.equals(typeName2) );
-
-    // we are intentionally non-compliant with the SDO spec in naming anonymous types,
-    // since the spec is broken, currently anonymous types have unique names and emtpy uri's
-    // http://bugzilla.cvo.example.com/show_bug.cgi?id=3469
-//     assertEquals( "http://www.example.com/xsd/48/", p1.getType().getURI() );
-//     assertEquals( "http://www.example.com/xsd/48/", p2.getType().getURI() );
-
-  }
-
-  @Test public void testQualified() {
-
-    // elements and attributes qualified
-    {
-      String schema =
-        "<?xml version='1.0' encoding='ISO-8859-1' ?>" +
-        "<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' " +
-        "targetNamespace='http://www.example.com/xsd/qualified/' " +
-        "elementFormDefault='qualified' attributeFormDefault='qualified'>" +
-        "<xs:complexType name='foo'>" +
-        "<xs:sequence>" +
-        "<xs:element name='bar' type='xs:string'/>" +
-        "</xs:sequence>" +
-        "<xs:attribute name='baz' type='xs:string'/>" +
-        "</xs:complexType>" +
-        "</xs:schema>";
-
-      xsdHelper.define(schema);
-
-      DataObject foo = testHelper.getDataFactory().create("http://www.example.com/xsd/qualified/", "foo");
-      foo.setString("bar", "barValue");
-      foo.setString("baz", "bazValue");
-
-      String out = testHelper.getXMLHelper().save(foo, "http://www.example.com/xsd/qualified/", "foo");
-
-      String expected =
-        "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" +
-        "<ns0:foo xmlns:ns0=\"http://www.example.com/xsd/qualified/\" " +
-        "ns0:baz=\"bazValue\">" +
-        "<ns0:bar>barValue</ns0:bar>" +
-        "</ns0:foo>";
-
-      assertEquals(expected, out);
-    }
-    // elements qualfied, attributes unqualified
-    {
-      String schema =
-        "<?xml version='1.0' encoding='ISO-8859-1' ?>" +
-        "<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' " +
-        "targetNamespace='http://www.example.com/xsd/qualified2/' " +
-        "elementFormDefault='qualified' attributeFormDefault='unqualified'>" +
-        "<xs:complexType name='foo'>" +
-        "<xs:sequence>" +
-        "<xs:element name='bar' type='xs:string'/>" +
-        "</xs:sequence>" +
-        "<xs:attribute name='baz' type='xs:string'/>" +
-        "</xs:complexType>" +
-        "</xs:schema>";
-
-      xsdHelper.define(schema);
-
-      DataObject foo = testHelper.getDataFactory().create("http://www.example.com/xsd/qualified2/", "foo");
-      foo.setString("bar", "barValue");
-      foo.setString("baz", "bazValue");
-
-      String out = testHelper.getXMLHelper().save(foo, "http://www.example.com/xsd/qualified2/", "foo");
-
-      String expected =
-        "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" +
-        "<ns0:foo xmlns:ns0=\"http://www.example.com/xsd/qualified2/\" " +
-        "baz=\"bazValue\">" +
-        "<ns0:bar>barValue</ns0:bar>" +
-        "</ns0:foo>";
-
-      assertEquals(expected, out);
-    }
   }
 
 }



---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org