square / assertj-android

A set of AssertJ helpers geared toward testing Android.
https://square.github.io/assertj-android/
Apache License 2.0
1.58k stars 156 forks source link

Google Maps asserts using wrong class in super constructor #176

Closed Philio closed 9 years ago

Philio commented 9 years ago

Using Google Maps assertions caused a crash.

Example:

java.lang.ClassCastException: Cannot cast org.assertj.android.playservices.api.maps.CameraPositionAssert to com.google.android.gms.maps.model.CameraPosition
    at java.lang.Class.cast(Class.java:3369)
    at org.assertj.core.api.AbstractAssert.<init>(AbstractAssert.java:63)
    at org.assertj.android.playservices.api.maps.CameraPositionAssert.<init>(CameraPositionAssert.java:11)
    at org.assertj.android.playservices.api.Assertions.assertThat(Assertions.java:26)
    ...
JakeWharton commented 9 years ago

Yikes. How did the compiler not catch this?