question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Robolectric tests fail - Unable to extract the trust manager v3.1.1

See original GitHub issue

Robolectric tests fail with v3.1.1

java.lang.IllegalStateException: Unable to extract the trust manager on okhttp3.internal.Platform$Android@56bc3fac, sslSocketFactory is class sun.security.ssl.SSLSocketFactoryImpl
    at okhttp3.OkHttpClient.<init>(OkHttpClient.java:186)
    at okhttp3.OkHttpClient.<init>(OkHttpClient.java:151)

Related: #2323

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
swankjessecommented, Feb 9, 2016

@Jeff11 just curious - what happens if you rename the field that contains the fallback SSL socket factory to delegate ? We have a special, disgusting hack that’ll make that work possibly, even if that field is private.

0reactions
IgorGanapolskycommented, Feb 24, 2016

I am getting this same error now running a test on emulator. Using okhttp 3.1.1 and Robolectric 3.0. What are my options to solve this?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Robolectric tests fail in terminal, succeed in Android Studio
When ran from Android Studio (v3.6), all the tests pass successfully. Strangely, some of the tests fail when I'm running them using ....
Read more >
3.x Change Log - OkHttp
Fix: Don't crash when finding the trust manager on Robolectric. We attempted to detect the host platform and got confused because Robolectric looks...
Read more >
Diff - platform/frameworks/support - android Git repositories
Merge "Document upcoming studio macrobench integration" into androidx-main diff --git a/activity/OWNERS b/activity/OWNERS index ...
Read more >
A study of Pseudo-tested Methods in an Android Continuous ...
This study investigates mutation testing on an Android application. ... 1.1 Background . ... However, to detect flakiness in Robolectric tests, a custom....
Read more >
Robolectric Migration Guide
Robolectric provides an automated migration tool to help keep your test suite ... InflateException: Binary XML file line #3: Failed to resolve attribute...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found