Unable to run Android service test

I am unable to run an android service test from intellij.  I created the test project and run configuration okay, but when running the project I get a message saying "Unable to attach test reporter to test framework".  This happens whether I run a single test method, a test class or the generated run config for the whole project.  Below is the manifest.xml and test.  The name attribute of instrumentation element has the classname InstrumentationTestRunner in red as an error  Anybody have this same issue or have any troubleshooting suggestions?

Thanks

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
          package="com.foo.tests"
          android:versionCode="1"
          android:versionName="1.0">
    <application>
        <uses-library android:name="android.test.runner" />
    </application>
    <instrumentation android:name="android.test.InstrumentationTestRunner"
                     android:targetPackage="com.foo"
                     android:label="Tests for com.foo"/>
</manifest>




package com.foo.tests.service;

import android.content.Context;
import android.content.Intent;
import android.test.ServiceTestCase;
import com.foo.service.MyService;

public class MyServiceTest extends ServiceTestCase<MyService> {

    public LlamaPlayerServiceTest(Class<MyService> serviceClass) {
        super(serviceClass);
    }

    public void testSomething() {
        Context context = getContext();
        Intent intent = new Intent(context, MyService.class);
        startService(intent);
    }
}

2 comments
Comment actions Permalink

I'm having exactly the same issue.  It really worries me that no one has answered this question here.

Help!

Dale

0
Comment actions Permalink

StackOverflow comes thru!   It's a known issue: http://youtrack.jetbrains.net/issue/IDEA-76259

0

Please sign in to leave a comment.