Can you please show the full stack trace? There should be.a nested exception with the actual problem.


On 2. May 2023, at 09:30, 'George Pandian' via JaCoCo and EclEmma Users <jacoco@googlegroups.com> wrote:

Is this a known issue ? I see a quiet similar error being reported here.

Any help deeply appreciated please.

Use case:

I find this noise with jacoco and it errors in my Unit Test.
Step 1: In my HomeFeedViewModel class, I do a mapping between objects in my ModelMappers kotlin file,

Step 2: DM (Domain Model) -> UIM(UIModel)
sealed class MyFeedUIM
data class MyHeader(val title:String):MyFeedUIM()

Error while running my Unit Test IllegalClassFormatException.

java.lang.instrument.IllegalClassFormatException: Error while instrumenting sample/viewmodel/home/feed/ModelMappersKt with JaCoCo 0.8.8.202204050719/5dcf34a.
at org.jacoco.agent.rt.internal_b6258fc.CoverageTransformer.transform(CoverageTransformer.java:94)
at java.instrument/java.lang.instrument.ClassFileTransformer.transform(Unknown Source)
at java.instrument/sun.instrument.TransformerManager.transform(Unknown Source)
at java.instrument/sun.instrument.InstrumentationImpl.transform(Unknown Source)
at java.base/java.lang.ClassLoader.defineClass1(Native Method)
at java.base/java.lang.ClassLoader.defineClass(Unknown Source)
at java.base/java.security.SecureClassLoader.defineClass(Unknown Source)
at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(Unknown Source)
at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(Unknown Source)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(Unknown Source)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(Unknown Source)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(Unknown Source)
at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
at sample.viewmodel.home.feed.HomeFeedViewModel$loadHomeFeed$2.invokeSuspend(HomeFeedViewModel.kt:28)

--
You received this message because you are subscribed to the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jacoco+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/5b0538bc-8ee8-4934-bbcd-7fb0d1286797n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jacoco+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/33BF70DF-50A1-456B-AD4C-FCA9C3F20E76%40mountainminds.com.

Reply via email to