Leanplum / Leanplum-Android-SDK

Leanplum's integrated solution delivers meaningful engagement across messaging and the in-app experience.
https://www.leanplum.com
Apache License 2.0
46 stars 40 forks source link

Fix start callbacks to be invoked on failure. #402

Closed hborisoff closed 4 years ago

hborisoff commented 4 years ago
What Where/Who
JIRA Issue LP-11342
People Involved @hborisoff

Background

In some cases the start callbacks were not invoked when exception is thrown during HTTP call. After this fix all waiting callbacks will be invoked on a failure.

Two unit tests are added to verify that the callbacks are invoked on failure - one is for common exception from HTTP framework (this includes the SSL handshake exception), second is when response code is 500 (internal server error).