GCX-HCI / ThirtyInch

a MVP library for Android favoring a stateful Presenter
Apache License 2.0
1.03k stars 101 forks source link

#121: Use assertJ everywhere #128

Closed vpondala closed 6 years ago

vpondala commented 6 years ago

Migrated all assertions to AssertJ.

vpondala commented 6 years ago

My local build succeeded. This is my 1st Android build, not sure how to fix it, Can you please guide?

StefMa commented 6 years ago

Hey, thank you for your PR!

Sure. Try googeling for "Duplicate files copied in APK META-INF/License".

The problem is that two or more deoencies try to add these file into the apk. Which is not allowed. I am not hundred percent sure but it seems that the assertJ and the support test runner wants to include that file.

Just try to exclude it and the thirtyinch module and it should work 👍

On Oct 7, 2017 8:02 AM, "Vijayakrishna Pondala" notifications@github.com wrote:

My local build succeeded. This is my 1st Android build, not sure how to fix it, Can you please guide?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/grandcentrix/ThirtyInch/pull/128#issuecomment-334913110, or mute the thread https://github.com/notifications/unsubscribe-auth/AJwYe1j6wx5Ku4uTfMpablrqhA5rR_Ioks5spxQKgaJpZM4PxPjh .

vpondala commented 6 years ago

I added packagingOptions { exclude 'META-INF/LICENSE' } and the build passes now. Please have a look at the diffs and let me know if the changes look good.

passsy commented 6 years ago

There's a mixup between import static org.assertj.core.api.Assertions.*; and import static org.assertj.core.api.Java6Assertions.*;. The Java6Assertions was required for androidTests in the past. I'm not sure if this is still the case, AssertJ improved Android support a lot recently.

Try to use import static org.assertj.core.api.Assertions.*; everywhere

passsy commented 6 years ago

Thanks for your contribution!