Re: [Dev] [GREG] Error when adding JaCoco code coverage to test automation

2015-09-02 Thread Nuwan Wimalasekara
Hi Rajith,

I could generate coverage for the test module tests-resources successfully
in GReg 5.0.0-SNAPSHOT. I updated the test framework version to 4.4.2 and
change the pom configuration as the document. Then it generated the
coverage without any issue.

Which framework version have you used and which test module gives the above
error?

Thanks,
Nuwanw

On Wed, Sep 2, 2015 at 11:02 AM, Rajith Roshan  wrote:

> Hi all,
>
> Please find the correct doc link in [1] which, I referred when updating
> the test automation
>
> [1] -
> https://docs.google.com/document/d/1pMJGdRH4Kmc4J3rYzgnpGlR5AnSeoC4QL9gMX9tUhYs/edit#heading=h.yemie7ivahbz
> 
>
> Thanks!
> Rajith
>
> On Wed, Sep 2, 2015 at 10:57 AM, Rajith Roshan  wrote:
>
>> Hi Devs,
>>
>> I refer the doc [1] for updating Jacoco code coverage tool for
>> integration tests in product G-Reg. It builds successfully when code
>> coverage is set to false in automation.xml as follows.
>>
>> false
>>
>> Please do find automation.xml, pom.xml and automationlog files for the
>> respective test module in [2]
>>
>> [1] -
>> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>>
>> [2] -
>> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>>
>> But it gives the following error when code coverage is enabled. Further I
>> excluded "asm" from the jacoco dependency. But it gives the same error.
>> Any help will be appreciated.
>>
>>
>> ERROR
>> [org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener] -
>> Execution error occurred in TestExecutionListener:-
>> java.lang.reflect.InvocationTargetException
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>> at java.lang.reflect.Method.invoke(Method.java:606)
>> at
>> org.wso2.carbon.automation.engine.extensions.TestNGExtensionExecutor.executeExtensible(TestNGExtensionExecutor.java:75)
>> at
>> org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener.onExecutionFinish(TestExecutionListener.java:62)
>> at org.testng.TestNG.runExecutionListeners(TestNG.java:1033)
>> at org.testng.TestNG.run(TestNG.java:1013)
>> at
>> org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:178)
>> at
>> org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:92)
>> at
>> org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:96)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>> at java.lang.reflect.Method.invoke(Method.java:606)
>> at
>> org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
>> at
>> org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
>> at
>> org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
>> at
>> org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
>> at
>> org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)
>> Caused by: java.lang.IncompatibleClassChangeError: class
>> org.jacoco.core.internal.flow.ClassProbesVisitor has interface
>> org.objectweb.asm.ClassVisitor as super class
>> at java.lang.ClassLoader.defineClass1(Native Method)
>> at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
>> at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
>> at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
>> at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
>> at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
>> at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
>> at java.security.AccessController.doPrivileged(Native Method)
>> at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
>> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
>> at
>> org.wso2.carbon.automation.engine.frameworkutils.ReportGenerator.analyzeStructure(ReportGenerator.java:144)
>> at
>> org.wso2.carbon.automation.engine.frameworkutils.ReportGenerator.create(ReportGenerator.java:77)
>> at
>> org.wso2.carbon.automation.extensions.servers.carbonserver.CarbonServerManager.generateCoverageReport(CarbonServerManager.java:333)
>> at
>> 

Re: [Dev] [GREG] Error when adding JaCoco code coverage to test automation

2015-09-02 Thread Nuwan Wimalasekara
Hi Rajith,

I could reproduce the same error in test module cmis-tck. I will have a
look on this issue.

Thanks,
Nuwanw

On Wed, Sep 2, 2015 at 12:46 PM, Nuwan Wimalasekara  wrote:

> Hi Rajith,
>
> I could generate coverage for the test module tests-resources successfully
> in GReg 5.0.0-SNAPSHOT. I updated the test framework version to 4.4.2 and
> change the pom configuration as the document. Then it generated the
> coverage without any issue.
>
> Which framework version have you used and which test module gives the
> above error?
>
> Thanks,
> Nuwanw
>
> On Wed, Sep 2, 2015 at 11:02 AM, Rajith Roshan  wrote:
>
>> Hi all,
>>
>> Please find the correct doc link in [1] which, I referred when updating
>> the test automation
>>
>> [1] -
>> https://docs.google.com/document/d/1pMJGdRH4Kmc4J3rYzgnpGlR5AnSeoC4QL9gMX9tUhYs/edit#heading=h.yemie7ivahbz
>> 
>>
>> Thanks!
>> Rajith
>>
>> On Wed, Sep 2, 2015 at 10:57 AM, Rajith Roshan  wrote:
>>
>>> Hi Devs,
>>>
>>> I refer the doc [1] for updating Jacoco code coverage tool for
>>> integration tests in product G-Reg. It builds successfully when code
>>> coverage is set to false in automation.xml as follows.
>>>
>>> false
>>>
>>> Please do find automation.xml, pom.xml and automationlog files for the
>>> respective test module in [2]
>>>
>>> [1] -
>>> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>>>
>>> [2] -
>>> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>>>
>>> But it gives the following error when code coverage is enabled. Further
>>> I excluded "asm" from the jacoco dependency. But it gives the same error.
>>> Any help will be appreciated.
>>>
>>>
>>> ERROR
>>> [org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener] -
>>> Execution error occurred in TestExecutionListener:-
>>> java.lang.reflect.InvocationTargetException
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>>> at java.lang.reflect.Method.invoke(Method.java:606)
>>> at
>>> org.wso2.carbon.automation.engine.extensions.TestNGExtensionExecutor.executeExtensible(TestNGExtensionExecutor.java:75)
>>> at
>>> org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener.onExecutionFinish(TestExecutionListener.java:62)
>>> at org.testng.TestNG.runExecutionListeners(TestNG.java:1033)
>>> at org.testng.TestNG.run(TestNG.java:1013)
>>> at
>>> org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:178)
>>> at
>>> org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:92)
>>> at
>>> org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:96)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>>> at java.lang.reflect.Method.invoke(Method.java:606)
>>> at
>>> org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
>>> at
>>> org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
>>> at
>>> org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
>>> at
>>> org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
>>> at
>>> org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)
>>> Caused by: java.lang.IncompatibleClassChangeError: class
>>> org.jacoco.core.internal.flow.ClassProbesVisitor has interface
>>> org.objectweb.asm.ClassVisitor as super class
>>> at java.lang.ClassLoader.defineClass1(Native Method)
>>> at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
>>> at
>>> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
>>> at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
>>> at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
>>> at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
>>> at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
>>> at java.security.AccessController.doPrivileged(Native Method)
>>> at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
>>> at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
>>> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
>>> at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
>>> at
>>> org.wso2.carbon.automation.engine.frameworkutils.ReportGenerator.analyzeStructure(ReportGenerator.java:144)
>>> at
>>> 

Re: [Dev] [GREG] Error when adding JaCoco code coverage to test automation

2015-09-02 Thread Nuwan Wimalasekara
Hi Rajith,

The issue is with the asm dependency. asm dependency should be removed from
all dependencies. Please exclude the asm dependency
from org.wso2.carbon.registry.activities as well. This will solve above
issue.


org.wso2.carbon.registry
org.wso2.carbon.registry.activities


asm
asm




Thanks,
Nuwanw

On Wed, Sep 2, 2015 at 1:02 PM, Nuwan Wimalasekara  wrote:

> Hi Rajith,
>
> I could reproduce the same error in test module cmis-tck. I will have a
> look on this issue.
>
> Thanks,
> Nuwanw
>
> On Wed, Sep 2, 2015 at 12:46 PM, Nuwan Wimalasekara 
> wrote:
>
>> Hi Rajith,
>>
>> I could generate coverage for the test module tests-resources
>> successfully in GReg 5.0.0-SNAPSHOT. I updated the test framework version
>> to 4.4.2 and change the pom configuration as the document. Then it
>> generated the coverage without any issue.
>>
>> Which framework version have you used and which test module gives the
>> above error?
>>
>> Thanks,
>> Nuwanw
>>
>> On Wed, Sep 2, 2015 at 11:02 AM, Rajith Roshan  wrote:
>>
>>> Hi all,
>>>
>>> Please find the correct doc link in [1] which, I referred when updating
>>> the test automation
>>>
>>> [1] -
>>> https://docs.google.com/document/d/1pMJGdRH4Kmc4J3rYzgnpGlR5AnSeoC4QL9gMX9tUhYs/edit#heading=h.yemie7ivahbz
>>> 
>>>
>>> Thanks!
>>> Rajith
>>>
>>> On Wed, Sep 2, 2015 at 10:57 AM, Rajith Roshan  wrote:
>>>
 Hi Devs,

 I refer the doc [1] for updating Jacoco code coverage tool for
 integration tests in product G-Reg. It builds successfully when code
 coverage is set to false in automation.xml as follows.

 false

 Please do find automation.xml, pom.xml and automationlog files for the
 respective test module in [2]

 [1] -
 https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing

 [2] -
 https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing

 But it gives the following error when code coverage is enabled. Further
 I excluded "asm" from the jacoco dependency. But it gives the same error.
 Any help will be appreciated.


 ERROR
 [org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener] -
 Execution error occurred in TestExecutionListener:-
 java.lang.reflect.InvocationTargetException
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at
 sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
 at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.lang.reflect.Method.invoke(Method.java:606)
 at
 org.wso2.carbon.automation.engine.extensions.TestNGExtensionExecutor.executeExtensible(TestNGExtensionExecutor.java:75)
 at
 org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener.onExecutionFinish(TestExecutionListener.java:62)
 at org.testng.TestNG.runExecutionListeners(TestNG.java:1033)
 at org.testng.TestNG.run(TestNG.java:1013)
 at
 org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:178)
 at
 org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:92)
 at
 org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:96)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at
 sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
 at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.lang.reflect.Method.invoke(Method.java:606)
 at
 org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
 at
 org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
 at
 org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
 at
 org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
 at
 org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)
 Caused by: java.lang.IncompatibleClassChangeError: class
 org.jacoco.core.internal.flow.ClassProbesVisitor has interface
 org.objectweb.asm.ClassVisitor as super class
 at java.lang.ClassLoader.defineClass1(Native Method)
 at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
 at
 java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
 at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
 at 

Re: [Dev] [GREG] Error when adding JaCoco code coverage to test automation

2015-09-02 Thread Krishantha Samaraweera
Fix for this issue is already specified there in the doc [1]
under Troubleshooting section.

Thanks,
Krishantha.

[1]
https://docs.google.com/a/wso2.com/document/d/1pMJGdRH4Kmc4J3rYzgnpGlR5AnSeoC4QL9gMX9tUhYs/edit?usp=sharing

On Wed, Sep 2, 2015 at 10:57 AM, Rajith Roshan  wrote:

> Hi Devs,
>
> I refer the doc [1] for updating Jacoco code coverage tool for integration
> tests in product G-Reg. It builds successfully when code coverage is set to
> false in automation.xml as follows.
>
> false
>
> Please do find automation.xml, pom.xml and automationlog files for the
> respective test module in [2]
>
> [1] -
> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>
> [2] -
> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>
> But it gives the following error when code coverage is enabled. Further I
> excluded "asm" from the jacoco dependency. But it gives the same error.
> Any help will be appreciated.
>
>
> ERROR
> [org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener] -
> Execution error occurred in TestExecutionListener:-
> java.lang.reflect.InvocationTargetException
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at
> org.wso2.carbon.automation.engine.extensions.TestNGExtensionExecutor.executeExtensible(TestNGExtensionExecutor.java:75)
> at
> org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener.onExecutionFinish(TestExecutionListener.java:62)
> at org.testng.TestNG.runExecutionListeners(TestNG.java:1033)
> at org.testng.TestNG.run(TestNG.java:1013)
> at
> org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:178)
> at
> org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:92)
> at
> org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:96)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at
> org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
> at
> org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
> at
> org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
> at
> org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
> at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)
> Caused by: java.lang.IncompatibleClassChangeError: class
> org.jacoco.core.internal.flow.ClassProbesVisitor has interface
> org.objectweb.asm.ClassVisitor as super class
> at java.lang.ClassLoader.defineClass1(Native Method)
> at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
> at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
> at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
> at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
> at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
> at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
> at
> org.wso2.carbon.automation.engine.frameworkutils.ReportGenerator.analyzeStructure(ReportGenerator.java:144)
> at
> org.wso2.carbon.automation.engine.frameworkutils.ReportGenerator.create(ReportGenerator.java:77)
> at
> org.wso2.carbon.automation.extensions.servers.carbonserver.CarbonServerManager.generateCoverageReport(CarbonServerManager.java:333)
> at
> org.wso2.carbon.automation.extensions.servers.carbonserver.CarbonServerManager.serverShutdown(CarbonServerManager.java:309)
> at
> org.wso2.carbon.automation.extensions.servers.carbonserver.TestServerManager.stopServer(TestServerManager.java:132)
> at
> org.wso2.carbon.automation.extensions.servers.carbonserver.CarbonServerExtension.onExecutionFinish(CarbonServerExtension.java:61)
> ... 20 more
> org.apache.maven.surefire.util.SurefireReflectionException:
> java.lang.reflect.InvocationTargetException; nested exception is
> java.lang.reflect.InvocationTargetException: null
> java.lang.reflect.InvocationTargetException
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> 

Re: [Dev] [GREG] Error when adding JaCoco code coverage to test automation

2015-09-02 Thread Rajith Roshan
Hi Nuwan,

It worked after excluding the dependency from registry.activities as well.
Thanks a lot for the help.

Thanks!
Rajith

On Wed, Sep 2, 2015 at 2:47 PM, Nuwan Wimalasekara  wrote:

> Hi Rajith,
>
> The issue is with the asm dependency. asm dependency should be removed
> from all dependencies. Please exclude the asm dependency
> from org.wso2.carbon.registry.activities as well. This will solve above
> issue.
>
> 
> org.wso2.carbon.registry
> org.wso2.carbon.registry.activities
> 
> 
> asm
> asm
> 
> 
> 
>
> Thanks,
> Nuwanw
>
> On Wed, Sep 2, 2015 at 1:02 PM, Nuwan Wimalasekara 
> wrote:
>
>> Hi Rajith,
>>
>> I could reproduce the same error in test module cmis-tck. I will have a
>> look on this issue.
>>
>> Thanks,
>> Nuwanw
>>
>> On Wed, Sep 2, 2015 at 12:46 PM, Nuwan Wimalasekara 
>> wrote:
>>
>>> Hi Rajith,
>>>
>>> I could generate coverage for the test module tests-resources
>>> successfully in GReg 5.0.0-SNAPSHOT. I updated the test framework version
>>> to 4.4.2 and change the pom configuration as the document. Then it
>>> generated the coverage without any issue.
>>>
>>> Which framework version have you used and which test module gives the
>>> above error?
>>>
>>> Thanks,
>>> Nuwanw
>>>
>>> On Wed, Sep 2, 2015 at 11:02 AM, Rajith Roshan  wrote:
>>>
 Hi all,

 Please find the correct doc link in [1] which, I referred when updating
 the test automation

 [1] -
 https://docs.google.com/document/d/1pMJGdRH4Kmc4J3rYzgnpGlR5AnSeoC4QL9gMX9tUhYs/edit#heading=h.yemie7ivahbz
 

 Thanks!
 Rajith

 On Wed, Sep 2, 2015 at 10:57 AM, Rajith Roshan 
 wrote:

> Hi Devs,
>
> I refer the doc [1] for updating Jacoco code coverage tool for
> integration tests in product G-Reg. It builds successfully when code
> coverage is set to false in automation.xml as follows.
>
> false
>
> Please do find automation.xml, pom.xml and automationlog files for the
> respective test module in [2]
>
> [1] -
> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>
> [2] -
> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>
> But it gives the following error when code coverage is enabled.
> Further I excluded "asm" from the jacoco dependency. But it gives the same
> error.
> Any help will be appreciated.
>
>
> ERROR
> [org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener] -
> Execution error occurred in TestExecutionListener:-
> java.lang.reflect.InvocationTargetException
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at
> org.wso2.carbon.automation.engine.extensions.TestNGExtensionExecutor.executeExtensible(TestNGExtensionExecutor.java:75)
> at
> org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener.onExecutionFinish(TestExecutionListener.java:62)
> at org.testng.TestNG.runExecutionListeners(TestNG.java:1033)
> at org.testng.TestNG.run(TestNG.java:1013)
> at
> org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:178)
> at
> org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:92)
> at
> org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:96)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at
> org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
> at
> org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
> at
> org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
> at
> org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
> at
> org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)
> Caused by: java.lang.IncompatibleClassChangeError: class
> 

Re: [Dev] [GREG] Error when adding JaCoco code coverage to test automation

2015-09-01 Thread Rajith Roshan
Hi all,

Please find the correct doc link in [1] which, I referred when updating the
test automation

[1] -
https://docs.google.com/document/d/1pMJGdRH4Kmc4J3rYzgnpGlR5AnSeoC4QL9gMX9tUhYs/edit#heading=h.yemie7ivahbz


Thanks!
Rajith

On Wed, Sep 2, 2015 at 10:57 AM, Rajith Roshan  wrote:

> Hi Devs,
>
> I refer the doc [1] for updating Jacoco code coverage tool for integration
> tests in product G-Reg. It builds successfully when code coverage is set to
> false in automation.xml as follows.
>
> false
>
> Please do find automation.xml, pom.xml and automationlog files for the
> respective test module in [2]
>
> [1] -
> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>
> [2] -
> https://drive.google.com/a/wso2.com/folderview?id=0B8xmd1n2DieYfjk2X0Fnb20yMUF0TnI1X1NIek5zTXFtUmhhU0wxRXFTQ1lCQ19qSlN5RmM=sharing
>
> But it gives the following error when code coverage is enabled. Further I
> excluded "asm" from the jacoco dependency. But it gives the same error.
> Any help will be appreciated.
>
>
> ERROR
> [org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener] -
> Execution error occurred in TestExecutionListener:-
> java.lang.reflect.InvocationTargetException
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at
> org.wso2.carbon.automation.engine.extensions.TestNGExtensionExecutor.executeExtensible(TestNGExtensionExecutor.java:75)
> at
> org.wso2.carbon.automation.engine.testlisteners.TestExecutionListener.onExecutionFinish(TestExecutionListener.java:62)
> at org.testng.TestNG.runExecutionListeners(TestNG.java:1033)
> at org.testng.TestNG.run(TestNG.java:1013)
> at
> org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:178)
> at
> org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:92)
> at
> org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:96)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at
> org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
> at
> org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
> at
> org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
> at
> org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
> at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)
> Caused by: java.lang.IncompatibleClassChangeError: class
> org.jacoco.core.internal.flow.ClassProbesVisitor has interface
> org.objectweb.asm.ClassVisitor as super class
> at java.lang.ClassLoader.defineClass1(Native Method)
> at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
> at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
> at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
> at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
> at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
> at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
> at
> org.wso2.carbon.automation.engine.frameworkutils.ReportGenerator.analyzeStructure(ReportGenerator.java:144)
> at
> org.wso2.carbon.automation.engine.frameworkutils.ReportGenerator.create(ReportGenerator.java:77)
> at
> org.wso2.carbon.automation.extensions.servers.carbonserver.CarbonServerManager.generateCoverageReport(CarbonServerManager.java:333)
> at
> org.wso2.carbon.automation.extensions.servers.carbonserver.CarbonServerManager.serverShutdown(CarbonServerManager.java:309)
> at
> org.wso2.carbon.automation.extensions.servers.carbonserver.TestServerManager.stopServer(TestServerManager.java:132)
> at
> org.wso2.carbon.automation.extensions.servers.carbonserver.CarbonServerExtension.onExecutionFinish(CarbonServerExtension.java:61)
> ... 20 more
> org.apache.maven.surefire.util.SurefireReflectionException:
> java.lang.reflect.InvocationTargetException; nested exception is
> java.lang.reflect.InvocationTargetException: null
>