[ http://issues.apache.org/jira/browse/TUSCANY-210?page=all ]
Jojo Joseph updated TUSCANY-210: -------------------------------- Attachment: patch.txt By default the generated WSDLs are stored in 'target/GeneratedWSDLs' folder. So the code fails if the 'target' folder deos not exist. I have a patch for this problem, which is attached here. Ant, would you be able to review this patch ? Thanks, jojo. > TuscanyJava2WsdlTestCase testcases break build > ---------------------------------------------- > > Key: TUSCANY-210 > URL: http://issues.apache.org/jira/browse/TUSCANY-210 > Project: Tuscany > Type: Bug > Components: Java SCA Tools > Reporter: Jim Marino > Assignee: ant elder > Priority: Critical > Attachments: patch.txt > > TuscanyJava2WsdlTestCase throws an exception when invoked from the main > build, likely due to a relative path issue. This offending testcases have > been commented out as a temporary workaround. > [INFO] > ---------------------------------------------------------------------------- > [INFO] Building Tuscany SCA Tools > [INFO] task-segment: [install] > [INFO] > ---------------------------------------------------------------------------- > org.apache.axis2.wsdl.codegen.CodeGenerationException: > java.io.IOException: No such file or directory > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.resolveOutputStream > (Java2WSDLGeneratorImpl.java:210) > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.initialize > (Java2WSDLGeneratorImpl.java:132) > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.generateWSDLModel > (Java2WSDLGeneratorImpl.java:272) > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.generateWSDL > (Java2WSDLGeneratorImpl.java:314) > at org.apache.tuscany.tools.java2wsdl.generate.Java2WSDL.main( > Java2WSDL.java:13) > at > org.apache.tuscany.tools.java2wsdl.generate.TuscanyJava2WsdlTestCase.testSimpleWsdlGeneration > (TuscanyJava2WsdlTestCase.java:41) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at junit.framework.TestCase.runTest(TestCase.java:154) > at junit.framework.TestCase.runBare(TestCase.java:127) > at junit.framework.TestResult$1.protect(TestResult.java:106) > at junit.framework.TestResult.runProtected(TestResult.java:124) > at junit.framework.TestResult.run(TestResult.java:109) > at junit.framework.TestCase.run(TestCase.java:118) > at junit.framework.TestSuite.runTest(TestSuite.java:208) > at junit.framework.TestSuite.run(TestSuite.java:203) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.apache.maven.surefire.battery.JUnitBattery.executeJUnit( > JUnitBattery.java:242) > at org.apache.maven.surefire.battery.JUnitBattery.execute( > JUnitBattery.java:216) > at org.apache.maven.surefire.Surefire.executeBattery( > Surefire.java:215) > at org.apache.maven.surefire.Surefire.run(Surefire.java:163) > at org.apache.maven.surefire.Surefire.run(Surefire.java:87) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.apache.maven.surefire.SurefireBooter.runTestsInProcess( > SurefireBooter.java:285) > at org.apache.maven.surefire.SurefireBooter.run( > SurefireBooter.java:201) > at org.apache.maven.test.SurefirePlugin.execute( > SurefirePlugin.java:366) > at org.apache.maven.plugin.DefaultPluginManager.executeMojo( > DefaultPluginManager.java:432) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals( > DefaultLifecycleExecutor.java:530) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle > (DefaultLifecycleExecutor.java:472) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal( > DefaultLifecycleExecutor.java:451) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures > (DefaultLifecycleExecutor.java:303) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments( > DefaultLifecycleExecutor.java:270) > at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute( > DefaultLifecycleExecutor.java:139) > at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java > :322) > at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115) > at org.apache.maven.cli.MavenCli.main(MavenCli.java:249) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.codehaus.classworlds.Launcher.launchEnhanced( > Launcher.java:315) > at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) > at org.codehaus.classworlds.Launcher.mainWithExitCode( > Launcher.java:430) > at org.codehaus.classworlds.Launcher.main(Launcher.java:375) > Caused by: java.io.IOException: No such file or directory > at java.io.UnixFileSystem.createFileExclusively(Native Method) > at java.io.File.createNewFile(File.java:850) > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.resolveOutputStream > (Java2WSDLGeneratorImpl.java:206) > ... 51 more > org.apache.axis2.wsdl.codegen.CodeGenerationException: > java.io.IOException: No such file or directory > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.resolveOutputStream > (Java2WSDLGeneratorImpl.java:210) > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.initialize > (Java2WSDLGeneratorImpl.java:132) > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.generateWSDLModel > (Java2WSDLGeneratorImpl.java:272) > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.generateWSDL > (Java2WSDLGeneratorImpl.java:314) > at org.apache.tuscany.tools.java2wsdl.generate.Java2WSDL.main( > Java2WSDL.java:13) > at > org.apache.tuscany.tools.java2wsdl.generate.TuscanyJava2WsdlTestCase.testWsdlGeneration2 > (TuscanyJava2WsdlTestCase.java:56) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at junit.framework.TestCase.runTest(TestCase.java:154) > at junit.framework.TestCase.runBare(TestCase.java:127) > at junit.framework.TestResult$1.protect(TestResult.java:106) > at junit.framework.TestResult.runProtected(TestResult.java:124) > at junit.framework.TestResult.run(TestResult.java:109) > at junit.framework.TestCase.run(TestCase.java:118) > at junit.framework.TestSuite.runTest(TestSuite.java:208) > at junit.framework.TestSuite.run(TestSuite.java:203) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.apache.maven.surefire.battery.JUnitBattery.executeJUnit( > JUnitBattery.java:242) > at org.apache.maven.surefire.battery.JUnitBattery.execute( > JUnitBattery.java:216) > at org.apache.maven.surefire.Surefire.executeBattery( > Surefire.java:215) > at org.apache.maven.surefire.Surefire.run(Surefire.java:163) > at org.apache.maven.surefire.Surefire.run(Surefire.java:87) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.apache.maven.surefire.SurefireBooter.runTestsInProcess( > SurefireBooter.java:285) > at org.apache.maven.surefire.SurefireBooter.run( > SurefireBooter.java:201) > at org.apache.maven.test.SurefirePlugin.execute( > SurefirePlugin.java:366) > at org.apache.maven.plugin.DefaultPluginManager.executeMojo( > DefaultPluginManager.java:432) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals( > DefaultLifecycleExecutor.java:530) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle > (DefaultLifecycleExecutor.java:472) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal( > DefaultLifecycleExecutor.java:451) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures > (DefaultLifecycleExecutor.java:303) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments( > DefaultLifecycleExecutor.java:270) > at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute( > DefaultLifecycleExecutor.java:139) > at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java > :322) > at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115) > at org.apache.maven.cli.MavenCli.main(MavenCli.java:249) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.codehaus.classworlds.Launcher.launchEnhanced( > Launcher.java:315) > at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) > at org.codehaus.classworlds.Launcher.mainWithExitCode( > Launcher.java:430) > at org.codehaus.classworlds.Launcher.main(Launcher.java:375) > Caused by: java.io.IOException: No such file or directory > at java.io.UnixFileSystem.createFileExclusively(Native Method) > at java.io.File.createNewFile(File.java:850) > at > org.apache.tuscany.tools.java2wsdl.generate.Java2WSDLGeneratorImpl.resolveOutputStream > (Java2WSDLGeneratorImpl.java:206) > ... 51 more > [surefire] Running > org.apache.tuscany.tools.java2wsdl.generate.TuscanyJava2WsdlTestCase > [surefire] Tests run: 3, Failures: 2, Errors: 0, Time elapsed: 0.305 sec > [surefire] > [surefire] testSimpleWsdlGeneration( > org.apache.tuscany.tools.java2wsdl.generate.TuscanyJava2WsdlTestCase) > Time elapsed: 0.233 sec <<< FAILURE! > junit.framework.AssertionFailedError > at junit.framework.Assert.fail(Assert.java:47) > at junit.framework.Assert.assertTrue(Assert.java:20) > at junit.framework.Assert.assertTrue(Assert.java:27) > at > org.apache.tuscany.tools.java2wsdl.generate.TuscanyJava2WsdlTestCase.testSimpleWsdlGeneration > (TuscanyJava2WsdlTestCase.java:44) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at junit.framework.TestCase.runTest(TestCase.java:154) > at junit.framework.TestCase.runBare(TestCase.java:127) > at junit.framework.TestResult$1.protect(TestResult.java:106) > at junit.framework.TestResult.runProtected(TestResult.java:124) > at junit.framework.TestResult.run(TestResult.java:109) > at junit.framework.TestCase.run(TestCase.java:118) > at junit.framework.TestSuite.runTest(TestSuite.java:208) > at junit.framework.TestSuite.run(TestSuite.java:203) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.apache.maven.surefire.battery.JUnitBattery.executeJUnit( > JUnitBattery.java:242) > at org.apache.maven.surefire.battery.JUnitBattery.execute( > JUnitBattery.java:216) > at org.apache.maven.surefire.Surefire.executeBattery( > Surefire.java:215) > at org.apache.maven.surefire.Surefire.run(Surefire.java:163) > at org.apache.maven.surefire.Surefire.run(Surefire.java:87) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.apache.maven.surefire.SurefireBooter.runTestsInProcess( > SurefireBooter.java:285) > at org.apache.maven.surefire.SurefireBooter.run( > SurefireBooter.java:201) > at org.apache.maven.test.SurefirePlugin.execute( > SurefirePlugin.java:366) > at org.apache.maven.plugin.DefaultPluginManager.executeMojo( > DefaultPluginManager.java:432) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals( > DefaultLifecycleExecutor.java:530) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle > (DefaultLifecycleExecutor.java:472) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal( > DefaultLifecycleExecutor.java:451) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures > (DefaultLifecycleExecutor.java:303) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments( > DefaultLifecycleExecutor.java:270) > at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute( > DefaultLifecycleExecutor.java:139) > at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java > :322) > at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115) > at org.apache.maven.cli.MavenCli.main(MavenCli.java:249) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.codehaus.classworlds.Launcher.launchEnhanced( > Launcher.java:315) > at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) > at org.codehaus.classworlds.Launcher.mainWithExitCode( > Launcher.java:430) > at org.codehaus.classworlds.Launcher.main(Launcher.java:375) > [surefire] testWsdlGeneration2( > org.apache.tuscany.tools.java2wsdl.generate.TuscanyJava2WsdlTestCase) > Time elapsed: 0.037 sec <<< FAILURE! > junit.framework.AssertionFailedError > at junit.framework.Assert.fail(Assert.java:47) > at junit.framework.Assert.assertTrue(Assert.java:20) > at junit.framework.Assert.assertTrue(Assert.java:27) > at > org.apache.tuscany.tools.java2wsdl.generate.TuscanyJava2WsdlTestCase.testWsdlGeneration2 > (TuscanyJava2WsdlTestCase.java:59) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at junit.framework.TestCase.runTest(TestCase.java:154) > at junit.framework.TestCase.runBare(TestCase.java:127) > at junit.framework.TestResult$1.protect(TestResult.java:106) > at junit.framework.TestResult.runProtected(TestResult.java:124) > at junit.framework.TestResult.run(TestResult.java:109) > at junit.framework.TestCase.run(TestCase.java:118) > at junit.framework.TestSuite.runTest(TestSuite.java:208) > at junit.framework.TestSuite.run(TestSuite.java:203) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.apache.maven.surefire.battery.JUnitBattery.executeJUnit( > JUnitBattery.java:242) > at org.apache.maven.surefire.battery.JUnitBattery.execute( > JUnitBattery.java:216) > at org.apache.maven.surefire.Surefire.executeBattery( > Surefire.java:215) > at org.apache.maven.surefire.Surefire.run(Surefire.java:163) > at org.apache.maven.surefire.Surefire.run(Surefire.java:87) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.apache.maven.surefire.SurefireBooter.runTestsInProcess( > SurefireBooter.java:285) > at org.apache.maven.surefire.SurefireBooter.run( > SurefireBooter.java:201) > at org.apache.maven.test.SurefirePlugin.execute( > SurefirePlugin.java:366) > at org.apache.maven.plugin.DefaultPluginManager.executeMojo( > DefaultPluginManager.java:432) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals( > DefaultLifecycleExecutor.java:530) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle > (DefaultLifecycleExecutor.java:472) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal( > DefaultLifecycleExecutor.java:451) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures > (DefaultLifecycleExecutor.java:303) > at > org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments( > DefaultLifecycleExecutor.java:270) > at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute( > DefaultLifecycleExecutor.java:139) > at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java > :322) > at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115) > at org.apache.maven.cli.MavenCli.main(MavenCli.java:249) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke( > NativeMethodAccessorImpl.java:39) > at sun.reflect.DelegatingMethodAccessorImpl.invoke( > DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at org.codehaus.classworlds.Launcher.launchEnhanced( > Launcher.java:315) > at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) > at org.codehaus.classworlds.Launcher.mainWithExitCode( > Launcher.java:430) > at org.codehaus.classworlds.Launcher.main(Launcher.java:375) -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira