Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
314 views
in Technique[技术] by (71.8m points)

Running Android unit test outside of gradle build tool - using java junit commandline?

I have a standard android project where I have an src/test folder with all my Junit test. However I want to run these tests outside of the Gradle build tool, I.e. the person running these tests does not need to pull the android project and run a gradle build. My thought is to build a test aar/jar file and run the tests via standard java command:

i.e. java -jar junit-platform-console-standalone-.jar test.jar

Would this work? I tried searching online but couldn't find example how to configure the gradle file correctly to build the right jar/aar to export.

question from:https://stackoverflow.com/questions/65951366/running-android-unit-test-outside-of-gradle-build-tool-using-java-junit-comman

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...