Summary:
Methods
| Inherited Methods
MockService
public
class
MockService
extends Object
| java.lang.Object | |
| ↳ | android.test.mock.MockService |
This class was deprecated
in API level 28.
Use a mocking framework like Mockito.
New tests should be written using the
Android Testing Support Library.
A mock Service class.
Provided for use by android.test.ServiceTestCase.
Summary
Public methods | |
|---|---|
static
<T extends Service>
void
|
attachForTesting(Service service, Context context, String serviceClassName, Application application)
|
Inherited methods | |
|---|---|
Public methods
attachForTesting
Added in API level 28
public static void attachForTesting (Service service, Context context, String serviceClassName, Application application)
| Parameters | |
|---|---|
service |
Service |
context |
Context |
serviceClassName |
String |
application |
Application |