Code Monkey home page Code Monkey logo

Comments (6)

Adambl4 avatar Adambl4 commented on May 24, 2024 1

1.0.12-SNAPSHOT made the fix.
Thank you!

from android-junit5.

mannodermaus avatar mannodermaus commented on May 24, 2024

What error are you facing when the product flavor is active? Starting with AGP3, each product flavor has to be assigned a dimension, which you declared, but didn't assign to the flavor (it should say dev { dimension "tier" }).

Here is an example from the plugin's unit tests. Please let me know if the error persists beyond that, and post a stack trace as well!

from android-junit5.

Adambl4 avatar Adambl4 commented on May 24, 2024

The problem is that it doesn't found Spek tests.
This is the result of ./gradlew junitPlatformTestDevDebug with an existing product flavour

Test run finished after 28 ms
[         3 containers found      ]
[         0 containers skipped    ]
[         3 containers started    ]
[         0 containers aborted    ]
[         3 containers successful ]
[         0 containers failed     ]
[         **0 tests found**       ]
[         0 tests skipped         ]
[         0 tests started         ]
[         0 tests aborted         ]
[         0 tests successful      ]
[         0 tests failed          ]

And this is of ./gradlew junitPlatformTest without a product flavour

Test run finished after 32 ms
[         4 containers found      ]
[         0 containers skipped    ]
[         4 containers started    ]
[         0 containers aborted    ]
[         4 containers successful ]
[         0 containers failed     ]
[         **1 tests found**       ]
[         0 tests skipped         ]
[         1 tests started         ]
[         0 tests aborted         ]
[         0 tests successful      ]
[         1 tests failed          ]

from android-junit5.

mannodermaus avatar mannodermaus commented on May 24, 2024

Thanks for elaborating! This looks like an issue with how the different source paths are fed into the flavor-aware sub tasks. I'll keep you posted.

from android-junit5.

mannodermaus avatar mannodermaus commented on May 24, 2024

Actually the problem wasn't how the JUnit tasks were set up, but rather where the intermediate Kotlin classes were copied to. If you used a Java test instead, it would have been picked up properly. After some writing, I have now introduced functional tests which will aid in verifying the behavior of the plugin with actual unit test sources.

On the latest snapshot of the plugin, 1.0.12-SNAPSHOT, this issue has been fixed, and it will be part of the next proper release, also due very shortly.

Thanks for reporting!

from android-junit5.

mannodermaus avatar mannodermaus commented on May 24, 2024

Released in 1.0.12!

from android-junit5.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.