Skip to content Skip to sidebar Skip to footer
Showing posts with the label Robolectric

Robolectric 2.4 Nosuchmethoderror Cannot Be Cast To Runtimeexception When Creating Activity

I am starting to use Robolectric in Android Studio. At first I wanted to create a simple test using… Read more Robolectric 2.4 Nosuchmethoderror Cannot Be Cast To Runtimeexception When Creating Activity

Testing With Robolectric In Eclipse

I am trying to run a simple test with Robolectric in eclipse. I followed this tutorial, but got thi… Read more Testing With Robolectric In Eclipse

Could Not Find Any Version That Matches Org.robolectric:robolectric:2.3.+

When syncing my Gradle project in Android Studio, I get the following error: Error:Could not find … Read more Could Not Find Any Version That Matches Org.robolectric:robolectric:2.3.+

Robolectric 3 Googleplayservicesnotavailableexception

I've just started to use Robolectric and wanted to know how to resolve Google Play Services. I&… Read more Robolectric 3 Googleplayservicesnotavailableexception

What Do I Need Enable Or Install To Get The Annotation @runwith

I want to create a simple test with Robolectric for Android Apps using Android Studio. Ok, it is m… Read more What Do I Need Enable Or Install To Get The Annotation @runwith

In Robolectric Test, How To Wait For Messages In The Main Looper To Be Run?

I'm testing a Service using Robolectric 3. Once run, it registers an anonymous BroadcastReceive… Read more In Robolectric Test, How To Wait For Messages In The Main Looper To Be Run?

Simpletestcursor Robolectric 3.0-- Compilation Issue

I am trying to test the cursor in my app. But for the following import I get the error message-- ca… Read more Simpletestcursor Robolectric 3.0-- Compilation Issue

Shadowing Getfilesdir() In Robolectric 3

I'd like to shadow Context.getFilesDir() in order to 'virtualize' the filesystem my ap… Read more Shadowing Getfilesdir() In Robolectric 3

Using Powermock And Robolectric - Incompatibleclasschangeerror

I'm trying to use PowerMockito to mock some static methods in Android Robolectric tests. I'… Read more Using Powermock And Robolectric - Incompatibleclasschangeerror

Android Instrumentation Test Java.lang.unsatisfiedlinkerror On Using Androidjunitrunner And Androidjunit4

I am using robolectric in our unit tests. Recently in our project, we are adding a new dependency f… Read more Android Instrumentation Test Java.lang.unsatisfiedlinkerror On Using Androidjunitrunner And Androidjunit4

Robolectric 3 With Fabric Crashlytics

I am trying to ShadowClass Crashlytics/Fabric so that Robotlectric 3 tests do not fail. What I hav… Read more Robolectric 3 With Fabric Crashlytics

How To Add Java 9 To Android Studio?

I am using Robolectric library and the latest version of it v4.3.1 requires Java 9 to run. I am try… Read more How To Add Java 9 To Android Studio?

Jacoco Doesn't Work With Robolectric Tests

I wanted to generate code coverage reports on my JUnit tests in my android project so I added the J… Read more Jacoco Doesn't Work With Robolectric Tests

Android Unit Testing With Robolectric Throws Error Androidmanifest.xml Not Found Or Not A File

I am trying to use Robolectric to run a test case on a App in Eclipse as described in this blog, bu… Read more Android Unit Testing With Robolectric Throws Error Androidmanifest.xml Not Found Or Not A File

Robolectric "warning: Unable To Find Path To Android Sdk"

I am using Robolectric without using maven to build, meaning I am using the Robolectric-with-depend… Read more Robolectric "warning: Unable To Find Path To Android Sdk"

Using Robolectric With Sqliteassethelper

I'm very new to Robolectric, so apologies in advance if I'm missing something obvious here.… Read more Using Robolectric With Sqliteassethelper

Robolectric Tests Fail On Shadowof

What might be the problem? My Robolectric tests ran fine a while ago, but now they all fail with th… Read more Robolectric Tests Fail On Shadowof

Robolectric Issue With Progressbar

I keep getting a RuntimeException from Robolectric when it tries to invoke an onCreate for an activ… Read more Robolectric Issue With Progressbar

Robolectric 3.0 Not Working With AppCompat 21+

After upgrading to AppCompat 21, a lot of our Robolectric tests fail. It looks like there is an iss… Read more Robolectric 3.0 Not Working With AppCompat 21+

Robolectric Tests Fail On ShadowOf

What might be the problem? My Robolectric tests ran fine a while ago, but now they all fail with th… Read more Robolectric Tests Fail On ShadowOf