Robolectric says “AndroidManifest.xml not found”

I’m assuming you’re trying to run the tests with JUnit. You can try two different things:

  1. Create a Custom TestRunner class, as shown here. Check the CustomTestRunner section, where you basically create a TestRunner that actually knows the right manifest to use. Specify your tests for them to run with your test runner, with the @Config annotation.
  2. (My preferred choice) Go the your JUnit configuration, Run > Edit Configurations. Notice the ‘Working Directory’ textbox. Append /app (for OSX and Linux) or \app (Windows), to the path written in the textbox. Try running again and it should work.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)