diff --git a/frameworks/ans/test/moduletest/mock/include/mock_bundle_manager.h b/frameworks/ans/test/moduletest/mock/include/mock_bundle_manager.h index fd4ac0f63f83da320a137fb47b9b3d22ca4d9d22..cc102a7358a8fdea074a893039e5315919a363e8 100644 --- a/frameworks/ans/test/moduletest/mock/include/mock_bundle_manager.h +++ b/frameworks/ans/test/moduletest/mock/include/mock_bundle_manager.h @@ -425,7 +425,7 @@ public: * @param bundleName Indicates the bundle name of the application whose data is to be cleared. * @return Returns true if the data cleared successfully; returns false otherwise. */ - virtual bool CleanBundleDataFiles(const std::string &bundleName) override + virtual bool CleanBundleDataFiles(const std::string &bundleName, const int userId) override { return true; } diff --git a/frameworks/ans/test/moduletest/mock/mock_bundle_mgr_proxy.cpp b/frameworks/ans/test/moduletest/mock/mock_bundle_mgr_proxy.cpp index cd58a48388c28f596e09b1eb2933dfb6492ffd46..5f1674281bb32dac75cad98cb72379f0b1ecee0c 100644 --- a/frameworks/ans/test/moduletest/mock/mock_bundle_mgr_proxy.cpp +++ b/frameworks/ans/test/moduletest/mock/mock_bundle_mgr_proxy.cpp @@ -24,7 +24,6 @@ namespace OHOS { namespace AppExecFwk { - BundleMgrProxy::BundleMgrProxy(const sptr &impl) : IRemoteProxy(impl) { } @@ -47,6 +46,7 @@ bool BundleMgrProxy::GetApplicationInfos( bool BundleMgrProxy::GetBundleInfo(const std::string &bundleName, const BundleFlag flag, BundleInfo &bundleInfo) { + bundleInfo.uid = 1; return true; } @@ -183,7 +183,7 @@ bool BundleMgrProxy::CleanBundleCacheFiles( return true; } -bool BundleMgrProxy::CleanBundleDataFiles(const std::string &bundleName) +bool BundleMgrProxy::CleanBundleDataFiles(const std::string &bundleName, const int userId) { return true; } @@ -277,6 +277,5 @@ bool BundleMgrProxy::SendTransactCmd(IBundleMgr::Message code, MessageParcel &da { return true; } - } // namespace AppExecFwk } // namespace OHOS diff --git a/services/test/moduletest/mock/include/mock_bundle_manager.h b/services/test/moduletest/mock/include/mock_bundle_manager.h index 960b2aa7ba3a36c6b849dbf2b88728dae7186684..6a550d69c09a9a581167e4ba344c3f76fcefe8f8 100644 --- a/services/test/moduletest/mock/include/mock_bundle_manager.h +++ b/services/test/moduletest/mock/include/mock_bundle_manager.h @@ -331,7 +331,7 @@ public: * @param bundleName Indicates the bundle name of the application whose data is to be cleared. * @return Returns true if the data cleared successfully; returns false otherwise. */ - virtual bool CleanBundleDataFiles(const std::string &bundleName) override + virtual bool CleanBundleDataFiles(const std::string &bundleName, const int userId) override { return true; } diff --git a/services/test/moduletest/mock/mock_bundle_mgr_proxy.cpp b/services/test/moduletest/mock/mock_bundle_mgr_proxy.cpp index 5738fc88159f6492dd145f45e311b2fdaa7c4911..232efcf27eef9a850389828a20d2e80f0d07157e 100644 --- a/services/test/moduletest/mock/mock_bundle_mgr_proxy.cpp +++ b/services/test/moduletest/mock/mock_bundle_mgr_proxy.cpp @@ -180,7 +180,7 @@ bool BundleMgrProxy::CleanBundleCacheFiles( return true; } -bool BundleMgrProxy::CleanBundleDataFiles(const std::string &bundleName) +bool BundleMgrProxy::CleanBundleDataFiles(const std::string &bundleName, const int userId) { return true; } @@ -274,6 +274,5 @@ bool BundleMgrProxy::SendTransactCmd(IBundleMgr::Message code, MessageParcel &da { return true; } - } // namespace AppExecFwk } // namespace OHOS