From: Sangyoon Jang Date: Tue, 16 Apr 2019 07:56:31 +0000 (+0900) Subject: Add comparing package attributes for ReadonlyUpdateUninstall test X-Git-Tag: submit/tizen/20190531.072406~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=fada1276828d6f603d243a8f507451bdac69afb0;p=platform%2Fcore%2Fappfw%2Ftpk-backend.git Add comparing package attributes for ReadonlyUpdateUninstall test Requires: - https://review.tizen.org/gerrit/c/platform/core/appfw/app-installers/+/203612 Change-Id: I8f1def6d86993b411c856bc1dd168d134cb7d149 Signed-off-by: Sangyoon Jang --- diff --git a/src/unit_tests/smoke_test.cc b/src/unit_tests/smoke_test.cc index d252a9b..1129003 100644 --- a/src/unit_tests/smoke_test.cc +++ b/src/unit_tests/smoke_test.cc @@ -695,12 +695,17 @@ TEST_F(PreloadSmokeTest, ReadonlyUpdateUninstallMode) { std::string exec = "basicui"; ASSERT_EQ(backend.InstallPreload(path), ci::AppInstaller::Result::OK); + ci::PkgQueryInterface pkg_query1(pkgid, params.test_user.uid); + PackageAttributes original(pkg_query1); ASSERT_EQ(backend.Install(path), ci::AppInstaller::Result::OK); ValidatePackage(pkgid, {appid, exec}, params); TestParameters nonreadonly_params(params); nonreadonly_params.is_readonly = false; ValidatePackage(pkgid, {appid, exec}, nonreadonly_params); ASSERT_EQ(backend.Uninstall(pkgid), ci::AppInstaller::Result::OK); + ci::PkgQueryInterface pkg_query2(pkgid, params.test_user.uid, true); + PackageAttributes restored(pkg_query2); + ASSERT_EQ(original, restored); ValidatePackage(pkgid, {appid, exec}, params); }