Hi,<br><br>I need to test my coding in djunit.<br><br>I am using djunit_0.8.4 & junit-3.8.2<br><br><br>When i run junit there is no problem,The same coding when i run in djunit there is same error in dxo.<br><br><span style="background-color: rgb(255, 102, 102);">@ConversionRule("'lastupdated':@projectmgnt.util.CalcUtil@getCurrentDate()," +</span><br style="background-color: rgb(255, 102, 102);">
<span style="background-color: rgb(255, 102, 102);"> "'basiccontractexcecutiondate':@projectmgnt.util.CalcUtil@convertDate(basiccontractexcecutiondate)," +</span><br style="background-color: rgb(255, 102, 102);">
<span style="background-color: rgb(255, 102, 102);"> "'registereddate':registereddate==null?@projectmgnt.util.CalcUtil@getCurrentDate():registereddate")</span><br style="background-color: rgb(255, 102, 102);">
<span style="background-color: rgb(255, 102, 102);"> public void convert(AbstractCustomermasterPage src,Customermaster dest);</span><br><br>this is my dxo coding.<br><br><span style="background-color: rgb(255, 255, 153);">public Class doCreatecustomermaster() {</span><br style="background-color: rgb(255, 255, 153);">
<br style="background-color: rgb(255, 255, 153);"><span style="background-color: rgb(255, 255, 153);">Customermaster customer = new Customermaster();</span><br style="background-color: rgb(255, 255, 153);"><br style="background-color: rgb(255, 255, 153);">
<span style="background-color: rgb(255, 255, 153);"> customermasterDxo.convert(this, customer);<br><br> customermasterBhv.insert(customer);</span><br style="background-color: rgb(255, 255, 153);"><br style="background-color: rgb(255, 255, 153);">
<span style="background-color: rgb(255, 255, 153);"> return CustomermasterConfirmPage.class;</span><br style="background-color: rgb(255, 255, 153);"><span style="background-color: rgb(255, 255, 153);">}</span><br>
this is my main function<br><br><span style="background-color: rgb(255, 153, 0);">public void testdoCreatecustomermaster() throws Exception{</span><br style="background-color: rgb(255, 153, 0);"><span style="background-color: rgb(255, 153, 0);"> </span><br style="background-color: rgb(255, 153, 0);">
<span style="background-color: rgb(255, 153, 0);"> customermasterCreatePage.customercode="test";</span><br style="background-color: rgb(255, 153, 0);"><span style="background-color: rgb(255, 153, 0);"> </span><br style="background-color: rgb(255, 153, 0);">
<span style="background-color: rgb(255, 153, 0);"> customermasterCreatePage.customername="test";</span><br style="background-color: rgb(255, 153, 0);"><span style="background-color: rgb(255, 153, 0);"> </span><br style="background-color: rgb(255, 153, 0);">
<span style="background-color: rgb(255, 153, 0);"> customermasterCreatePage.basiccontractexcecutiondate ="2009/01/11";</span><br style="background-color: rgb(255, 153, 0);"><span style="background-color: rgb(255, 153, 0);"> </span><br style="background-color: rgb(255, 153, 0);">
<span style="background-color: rgb(255, 153, 0);"> Class a = customermasterCreatePage.doCreatecustomermaster();</span><br style="background-color: rgb(255, 153, 0);"><span style="background-color: rgb(255, 153, 0);">}</span><br>
<br>This is my test class coding.<br><br><br>java.lang.reflect.InvocationTargetException<br> at sun.reflect.GeneratedMethodAccessor5.invoke(Unknown Source)<br> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)<br>
at java.lang.reflect.Method.invoke(Unknown Source)<br> at jp.co.dgic.testing.common.DJUnitClassLoader.getModifiedClass(DJUnitClassLoader.java:109)<br> at jp.co.dgic.testing.common.DJUnitClassLoader.findClass(DJUnitClassLoader.java:59)<br>
at java.lang.ClassLoader.loadClass(Unknown Source)<br> at jp.co.dgic.testing.common.DJUnitClassLoader.loadClass(DJUnitClassLoader.java:48)<br> at jp.co.dgic.testing.common.DJUnitEclipseClassLoader.loadClass(DJUnitEclipseClassLoader.java:59)<br>
at java.lang.ClassLoader.loadClass(Unknown Source)<br> at java.lang.ClassLoader.loadClass(Unknown Source)<br> at java.beans.Introspector.instantiate(Unknown Source)<br> at java.beans.Introspector.findExplicitBeanInfo(Unknown Source)<br>
at java.beans.Introspector.<init>(Unknown Source)<br> at java.beans.Introspector.getBeanInfo(Unknown Source)<br> at ognl.OgnlRuntime.getPropertyDescriptors(OgnlRuntime.java:1570)<br> at ognl.OgnlRuntime.getPropertyDescriptor(OgnlRuntime.java:1591)<br>
at ognl.OgnlRuntime.getGetMethod(OgnlRuntime.java:1348)<br> at ognl.OgnlRuntime.getMethodValue(OgnlRuntime.java:1004)<br> at ognl.ObjectPropertyAccessor.getPossibleProperty(ObjectPropertyAccessor.java:53)<br> at ognl.ObjectPropertyAccessor.getProperty(ObjectPropertyAccessor.java:121)<br>
at ognl.OgnlRuntime.getProperty(OgnlRuntime.java:1758)<br> at ognl.ASTProperty.getValueBody(ASTProperty.java:92)<br> at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:171)<br> at ognl.SimpleNode.getValue(SimpleNode.java:211)<br>
at ognl.ASTStaticMethod.getValueBody(ASTStaticMethod.java:63)<br> at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:171)<br> at ognl.SimpleNode.getValue(SimpleNode.java:211)<br> at ognl.ASTMap.getValueBody(ASTMap.java:90)<br>
at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:171)<br> at ognl.SimpleNode.getValue(SimpleNode.java:211)<br> at ognl.Ognl.getValue(Ognl.java:333)<br> at ognl.Ognl.getValue(Ognl.java:413)<br> at ognl.Ognl.getValue(Ognl.java:395)<br>
at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:100)<br> at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:65)<br> at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:50)<br> at org.seasar.extension.dxo.util.OgnlExpression.evaluate(OgnlExpression.java:53)<br>
at org.seasar.extension.dxo.converter.impl.ConversionContextImpl.<init>(ConversionContextImpl.java:178)<br> at org.seasar.extension.dxo.command.impl.AbstractDxoCommand.createContext(AbstractDxoCommand.java:126)<br>
at org.seasar.extension.dxo.command.impl.BeanToBeanDxoCommand.convertScalar(BeanToBeanDxoCommand.java:70)<br> at org.seasar.extension.dxo.command.impl.AbstractDxoCommand$ScalarConversionHelper.convert(AbstractDxoCommand.java:223)<br>
at org.seasar.extension.dxo.command.impl.AbstractDxoCommand.execute(AbstractDxoCommand.java:78)<br> at org.seasar.extension.dxo.DxoInterceptor.invoke(DxoInterceptor.java:57)<br> at projectmgnt.dxo.CustomermasterDxo$$EnhancedByS2AOP$$1979eb$$MethodInvocation$$convert0.proceed(MethodInvocationClassGenerator.java)<br>
at org.seasar.framework.aop.interceptors.TraceInterceptor.invoke(TraceInterceptor.java:56)<br> at projectmgnt.dxo.CustomermasterDxo$$EnhancedByS2AOP$$1979eb$$MethodInvocation$$convert0.proceed(MethodInvocationClassGenerator.java)<br>
at projectmgnt.dxo.CustomermasterDxo$$EnhancedByS2AOP$$1979eb.convert(CustomermasterDxo$$EnhancedByS2AOP$$1979eb.java)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage.doCreatecustomermaster(CustomermasterCreatePage.java:49)<br>
at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398.$$doCreatecustomermaster$$invokeSuperMethod$$(CustomermasterCreatePage$$EnhancedByS2AOP$$72d398.java)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398$$MethodInvocation$$doCreatecustomermaster0.proceed(MethodInvocationClassGenerator.java)<br>
at org.seasar.extension.tx.DefaultTransactionCallback.execute(DefaultTransactionCallback.java:58)<br> at org.seasar.extension.tx.adapter.JTATransactionManagerAdapter.required(JTATransactionManagerAdapter.java:65)<br>
at org.seasar.extension.tx.RequiredInterceptor.invoke(RequiredInterceptor.java:41)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398$$MethodInvocation$$doCreatecustomermaster0.proceed(MethodInvocationClassGenerator.java)<br>
at org.seasar.framework.aop.interceptors.ThrowsInterceptor.invoke(ThrowsInterceptor.java:79)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398$$MethodInvocation$$doCreatecustomermaster0.proceed(MethodInvocationClassGenerator.java)<br>
at org.seasar.framework.aop.interceptors.TraceInterceptor.invoke(TraceInterceptor.java:56)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398$$MethodInvocation$$doCreatecustomermaster0.proceed(MethodInvocationClassGenerator.java)<br>
at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398.doCreatecustomermaster(CustomermasterCreatePage$$EnhancedByS2AOP$$72d398.java)<br> at projectmgnt.web.customermaster.CustomermasterCreateTest.testdoCreatecustomermaster(CustomermasterCreateTest.java:27)<br>
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)<br> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)<br> at java.lang.reflect.Method.invoke(Unknown Source)<br>
at junit.framework.TestCase.runTest(TestCase.java:164)<br> at org.seasar.framework.unit.S2FrameworkTestCase.doRunTest(S2FrameworkTestCase.java:519)<br> at org.seasar.framework.unit.S2FrameworkTestCase.runBare(S2FrameworkTestCase.java:308)<br>
at junit.framework.TestResult$1.protect(TestResult.java:106)<br> at junit.framework.TestResult.runProtected(TestResult.java:124)<br> at junit.framework.TestResult.run(TestResult.java:109)<br> at junit.framework.TestCase.run(TestCase.java:120)<br>
at junit.framework.TestSuite.runTest(TestSuite.java:230)<br> at junit.framework.TestSuite.run(TestSuite.java:225)<br> at junit.framework.TestSuite.runTest(TestSuite.java:230)<br> at junit.framework.TestSuite.run(TestSuite.java:225)<br>
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)<br> at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)<br> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)<br>
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)<br> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)<br> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)<br>
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)<br> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)<br> at java.lang.reflect.Method.invoke(Unknown Source)<br>
at jp.co.dgic.eclipse.jdt.internal.junit.runner.DJUnitRunner.main(DJUnitRunner.java:49)<br>Caused by: java.io.IOException: Class not found<br> at org.objectweb.asm.ClassReader.a(Unknown Source)<br> at org.objectweb.asm.ClassReader.<init>(Unknown Source)<br>
at org.objectweb.asm.ClassReader.<init>(Unknown Source)<br> at jp.co.dgic.testing.common.asm.AsmClassReader.<init>(AsmClassReader.java:52)<br> at jp.co.dgic.testing.common.asm3x.AsmClassReader3x.<init>(AsmClassReader3x.java:14)<br>
at jp.co.dgic.testing.common.asm.AsmClassReader.createAsmClassReader(AsmClassReader.java:24)<br> at jp.co.dgic.testing.common.AsmClassModifier.getModifiedClass(AsmClassModifier.java:49)<br> ... 86 more<br>java.lang.reflect.InvocationTargetException<br>
at sun.reflect.GeneratedMethodAccessor5.invoke(Unknown Source)<br> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)<br> at java.lang.reflect.Method.invoke(Unknown Source)<br> at jp.co.dgic.testing.common.DJUnitClassLoader.getModifiedClass(DJUnitClassLoader.java:109)<br>
at jp.co.dgic.testing.common.DJUnitClassLoader.findClass(DJUnitClassLoader.java:59)<br> at java.lang.ClassLoader.loadClass(Unknown Source)<br> at jp.co.dgic.testing.common.DJUnitClassLoader.loadClass(DJUnitClassLoader.java:48)<br>
at jp.co.dgic.testing.common.DJUnitEclipseClassLoader.loadClass(DJUnitEclipseClassLoader.java:59)<br> at java.lang.ClassLoader.loadClass(Unknown Source)<br> at java.lang.ClassLoader.loadClass(Unknown Source)<br>
at java.beans.Introspector.instantiate(Unknown Source)<br> at java.beans.Introspector.findExplicitBeanInfo(Unknown Source)<br> at java.beans.Introspector.<init>(Unknown Source)<br> at java.beans.Introspector.getBeanInfo(Unknown Source)<br>
at ognl.OgnlRuntime.getPropertyDescriptors(OgnlRuntime.java:1570)<br> at ognl.OgnlRuntime.getPropertyDescriptor(OgnlRuntime.java:1591)<br> at ognl.OgnlRuntime.getGetMethod(OgnlRuntime.java:1348)<br> at ognl.OgnlRuntime.getMethodValue(OgnlRuntime.java:1004)<br>
at ognl.ObjectPropertyAccessor.getPossibleProperty(ObjectPropertyAccessor.java:53)<br> at ognl.ObjectPropertyAccessor.getProperty(ObjectPropertyAccessor.java:121)<br> at ognl.OgnlRuntime.getProperty(OgnlRuntime.java:1758)<br>
at ognl.ASTProperty.getValueBody(ASTProperty.java:92)<br> at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:171)<br> at ognl.SimpleNode.getValue(SimpleNode.java:211)<br> at ognl.ASTStaticMethod.getValueBody(ASTStaticMethod.java:63)<br>
at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:171)<br> at ognl.SimpleNode.getValue(SimpleNode.java:211)<br> at ognl.ASTMap.getValueBody(ASTMap.java:90)<br> at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:171)<br>
at ognl.SimpleNode.getValue(SimpleNode.java:211)<br> at ognl.Ognl.getValue(Ognl.java:333)<br> at ognl.Ognl.getValue(Ognl.java:413)<br> at ognl.Ognl.getValue(Ognl.java:395)<br> at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:100)<br>
at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:65)<br> at org.seasar.framework.util.OgnlUtil.getValue(OgnlUtil.java:50)<br> at org.seasar.extension.dxo.util.OgnlExpression.evaluate(OgnlExpression.java:53)<br>
at org.seasar.extension.dxo.converter.impl.ConversionContextImpl.<init>(ConversionContextImpl.java:178)<br> at org.seasar.extension.dxo.command.impl.AbstractDxoCommand.createContext(AbstractDxoCommand.java:126)<br>
at org.seasar.extension.dxo.command.impl.BeanToBeanDxoCommand.convertScalar(BeanToBeanDxoCommand.java:70)<br> at org.seasar.extension.dxo.command.impl.AbstractDxoCommand$ScalarConversionHelper.convert(AbstractDxoCommand.java:223)<br>
at org.seasar.extension.dxo.command.impl.AbstractDxoCommand.execute(AbstractDxoCommand.java:78)<br> at org.seasar.extension.dxo.DxoInterceptor.invoke(DxoInterceptor.java:57)<br> at projectmgnt.dxo.CustomermasterDxo$$EnhancedByS2AOP$$1979eb$$MethodInvocation$$convert0.proceed(MethodInvocationClassGenerator.java)<br>
at org.seasar.framework.aop.interceptors.TraceInterceptor.invoke(TraceInterceptor.java:56)<br> at projectmgnt.dxo.CustomermasterDxo$$EnhancedByS2AOP$$1979eb$$MethodInvocation$$convert0.proceed(MethodInvocationClassGenerator.java)<br>
at projectmgnt.dxo.CustomermasterDxo$$EnhancedByS2AOP$$1979eb.convert(CustomermasterDxo$$EnhancedByS2AOP$$1979eb.java)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage.doCreatecustomermaster(CustomermasterCreatePage.java:49)<br>
at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398.$$doCreatecustomermaster$$invokeSuperMethod$$(CustomermasterCreatePage$$EnhancedByS2AOP$$72d398.java)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398$$MethodInvocation$$doCreatecustomermaster0.proceed(MethodInvocationClassGenerator.java)<br>
at org.seasar.extension.tx.DefaultTransactionCallback.execute(DefaultTransactionCallback.java:58)<br> at org.seasar.extension.tx.adapter.JTATransactionManagerAdapter.required(JTATransactionManagerAdapter.java:65)<br>
at org.seasar.extension.tx.RequiredInterceptor.invoke(RequiredInterceptor.java:41)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398$$MethodInvocation$$doCreatecustomermaster0.proceed(MethodInvocationClassGenerator.java)<br>
at org.seasar.framework.aop.interceptors.ThrowsInterceptor.invoke(ThrowsInterceptor.java:79)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398$$MethodInvocation$$doCreatecustomermaster0.proceed(MethodInvocationClassGenerator.java)<br>
at org.seasar.framework.aop.interceptors.TraceInterceptor.invoke(TraceInterceptor.java:56)<br> at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398$$MethodInvocation$$doCreatecustomermaster0.proceed(MethodInvocationClassGenerator.java)<br>
at projectmgnt.web.customermaster.CustomermasterCreatePage$$EnhancedByS2AOP$$72d398.doCreatecustomermaster(CustomermasterCreatePage$$EnhancedByS2AOP$$72d398.java)<br> at projectmgnt.web.customermaster.CustomermasterCreateTest.testdoCreatecustomermaster(CustomermasterCreateTest.java:27)<br>
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)<br> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)<br> at java.lang.reflect.Method.invoke(Unknown Source)<br>
at junit.framework.TestCase.runTest(TestCase.java:164)<br> at org.seasar.framework.unit.S2FrameworkTestCase.doRunTest(S2FrameworkTestCase.java:519)<br> at org.seasar.framework.unit.S2FrameworkTestCase.runBare(S2FrameworkTestCase.java:308)<br>
at junit.framework.TestResult$1.protect(TestResult.java:106)<br> at junit.framework.TestResult.runProtected(TestResult.java:124)<br> at junit.framework.TestResult.run(TestResult.java:109)<br> at junit.framework.TestCase.run(TestCase.java:120)<br>
at junit.framework.TestSuite.runTest(TestSuite.java:230)<br> at junit.framework.TestSuite.run(TestSuite.java:225)<br> at junit.framework.TestSuite.runTest(TestSuite.java:230)<br> at junit.framework.TestSuite.run(TestSuite.java:225)<br>
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)<br> at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)<br> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)<br>
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)<br> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)<br> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)<br>
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)<br> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)<br> at java.lang.reflect.Method.invoke(Unknown Source)<br>
at jp.co.dgic.eclipse.jdt.internal.junit.runner.DJUnitRunner.main(DJUnitRunner.java:49)<br>Caused by: java.io.IOException: Class not found<br> at org.objectweb.asm.ClassReader.a(Unknown Source)<br> at org.objectweb.asm.ClassReader.<init>(Unknown Source)<br>
at org.objectweb.asm.ClassReader.<init>(Unknown Source)<br> at jp.co.dgic.testing.common.asm.AsmClassReader.<init>(AsmClassReader.java:52)<br> at jp.co.dgic.testing.common.asm3x.AsmClassReader3x.<init>(AsmClassReader3x.java:14)<br>
at jp.co.dgic.testing.common.asm.AsmClassReader.createAsmClassReader(AsmClassReader.java:24)<br> at jp.co.dgic.testing.common.AsmClassModifier.getModifiedClass(AsmClassModifier.java:49)<br> ... 86 more<br><br>I got these errors..<br>
<br>How can i solve these problem<br><br><br>if i change my conversion rule like this there is no problem<br><br><br><span style="background-color: rgb(255, 255, 0);">@ConversionRule("'lastupdated':@projectmgnt.util.CalcUtil@getCurrentDate()," +</span><br style="background-color: rgb(255, 255, 0);">
<span style="background-color: rgb(255, 255, 0);"> "'<b>basiccontractexcecutiondate':@projectmgnt.util.CalcUtil@convertDate('2008/11/11'')</b>," +</span><br style="background-color: rgb(255, 255, 0);">
<span style="background-color: rgb(255, 255, 0);">
</span><br style="background-color: rgb(255, 255, 0);">
<span style="background-color: rgb(255, 255, 0);"> public void convert(AbstractCustomermasterPage src,Customermaster dest);</span><br><br>thanks in advance,<br>トマス<br>