In addition to this code change, an additional import is also needed:

import org.apache.tuscany.contribution.resolver.DefaultArtifactResolver;

(the other) Simon

Simon Laws wrote:

I just made the following change in ImportSDOProcessorTestCase to make the
SDO tests work. See commented out/new line below. The loader in this case
dereferences the rolver so you can't pass in null without getting an NPE.
I'm not sure what the intention is here so I haven't checked this in. We
could either create the DefaultArtifactResolver here, test for null in the
loader and do nothing if null is passed in or preferably both.

 public void testFactory() throws Exception {
       String xml = "<import.sdo xmlns='
http://tuscany.apache.org/xmlns/sca/databinding/sdo/1.0' " + "factory='"
                    + MockFactory.class.getName()
                    + "'/>";
       XMLStreamReader reader = getReader(xml);
       assertFalse(inited);
       ImportSDO importSDO = loader.read(reader);
       assertNotNull(importSDO);
       //loader.resolve(importSDO, null);
       loader.resolve(importSDO, new DefaultArtifactResolver());
       assertTrue(inited);
   }

Simon




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to