lundi 16 mars 2020

Create Unit and Instrumentation test for Android project with dynamic features

I have a project where I have main :app package. Besides that, the app contains of two dynamic features inside the same package, :features:A and :features:B.

The issue here is that I can't run Unit and Instrumentation tests (Espresso, UI Automator) because of the following error(s):

“AAPT: error: resource string/app_name (aka com.app.A.test:string/app_name) not found.” 

When I run tests(UI tests in this case) App compiles and works without any issues.

I figured out that error occurs on manifest merging, as it can be seen from complete error:

/Users/user/company/app/features/A/build/intermediates/tmp/manifest/androidTest/app/debug/manifestMerger7870721738992192959.xml:7:5-9:19: AAPT: error: resource string/app_name (aka com.app.A.test:string/app_name) not found.

Thanks for the answer!

Aucun commentaire:

Enregistrer un commentaire