summaryrefslogtreecommitdiffstats
path: root/test-runner/src/android/test/ProviderTestCase2.java
diff options
context:
space:
mode:
Diffstat (limited to 'test-runner/src/android/test/ProviderTestCase2.java')
-rw-r--r--test-runner/src/android/test/ProviderTestCase2.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/test-runner/src/android/test/ProviderTestCase2.java b/test-runner/src/android/test/ProviderTestCase2.java
index 64d11c5..2811b0d 100644
--- a/test-runner/src/android/test/ProviderTestCase2.java
+++ b/test-runner/src/android/test/ProviderTestCase2.java
@@ -74,7 +74,7 @@ public abstract class ProviderTestCase2<T extends ContentProvider> extends Andro
private IsolatedContext mProviderContext;
private MockContentResolver mResolver;
- private class MockContext2 extends MockContext {
+ private class MockContext2 extends MockContext {
@Override
public Resources getResources() {
@@ -87,6 +87,11 @@ public abstract class ProviderTestCase2<T extends ContentProvider> extends Andro
// one created through the regular Context
return getContext().getDir("mockcontext2_" + name, mode);
}
+
+ @Override
+ public Context getApplicationContext() {
+ return this;
+ }
}
/**
* Constructor.