diff options
author | Glenn Kasten <gkasten@google.com> | 2014-03-26 20:00:10 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2014-03-26 20:00:11 +0000 |
commit | 1ee4eb074c2d85148658e93e865a18834bdced72 (patch) | |
tree | 9ac244717091a290c8c06a3de80b4eeb8d97679b /core/tests | |
parent | 460572b22fe8fe5880ad099090b38765e2f8a2f6 (diff) | |
parent | 7629a18a3f190368e6268d3f2827824905683268 (diff) | |
download | frameworks_base-1ee4eb074c2d85148658e93e865a18834bdced72.zip frameworks_base-1ee4eb074c2d85148658e93e865a18834bdced72.tar.gz frameworks_base-1ee4eb074c2d85148658e93e865a18834bdced72.tar.bz2 |
Merge "Revert "Expand install observer semantics""
Diffstat (limited to 'core/tests')
-rw-r--r-- | core/tests/coretests/src/android/content/pm/PackageManagerTests.java | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/core/tests/coretests/src/android/content/pm/PackageManagerTests.java b/core/tests/coretests/src/android/content/pm/PackageManagerTests.java index e77564f..04f8009 100644 --- a/core/tests/coretests/src/android/content/pm/PackageManagerTests.java +++ b/core/tests/coretests/src/android/content/pm/PackageManagerTests.java @@ -21,7 +21,6 @@ import static libcore.io.OsConstants.*; import com.android.frameworks.coretests.R; import com.android.internal.content.PackageHelper; -import android.app.PackageInstallObserver; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; @@ -32,7 +31,6 @@ import android.content.pm.PackageManager.NameNotFoundException; import android.content.res.Resources; import android.content.res.Resources.NotFoundException; import android.net.Uri; -import android.os.Bundle; import android.os.Environment; import android.os.FileUtils; import android.os.IBinder; @@ -119,12 +117,12 @@ public class PackageManagerTests extends AndroidTestCase { super.tearDown(); } - private class TestInstallObserver extends PackageInstallObserver { + private class PackageInstallObserver extends IPackageInstallObserver.Stub { public int returnCode; private boolean doneFlag = false; - public void packageInstalled(String packageName, Bundle extras, int returnCode) { + public void packageInstalled(String packageName, int returnCode) { synchronized (this) { this.returnCode = returnCode; doneFlag = true; @@ -205,7 +203,7 @@ public class PackageManagerTests extends AndroidTestCase { public void invokeInstallPackage(Uri packageURI, int flags, GenericReceiver receiver, boolean shouldSucceed) { - TestInstallObserver observer = new TestInstallObserver(); + PackageInstallObserver observer = new PackageInstallObserver(); mContext.registerReceiver(receiver, receiver.filter); try { // Wait on observer @@ -263,7 +261,7 @@ public class PackageManagerTests extends AndroidTestCase { } public void invokeInstallPackageFail(Uri packageURI, int flags, int expectedResult) { - TestInstallObserver observer = new TestInstallObserver(); + PackageInstallObserver observer = new PackageInstallObserver(); try { // Wait on observer synchronized (observer) { |