Validate file contents which are located at extracted dir 11/235411/1
authorSangyoon Jang <jeremy.jang@samsung.com>
Thu, 4 Jun 2020 08:58:38 +0000 (17:58 +0900)
committerSangyoon Jang <jeremy.jang@samsung.com>
Thu, 4 Jun 2020 09:03:32 +0000 (18:03 +0900)
When the package mount installed, some contents of package will be
extracted at package directory, because someone needs those files
without mounting zip file.
The test needs to validate those files recovered or rollbacked well or not.

Change-Id: Id72749b4cf5852f22bec30eaf3b52c157e13bc5d
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
src/unit_tests/smoke_test.cc
src/unit_tests/test_samples/smoke/MountUpdateMode_Rollback.tpk
src/unit_tests/test_samples/smoke/MountUpdateMode_Rollback2.tpk
src/unit_tests/test_samples/smoke/RecoveryMode_ForMountUpdate.tpk
src/unit_tests/test_samples/smoke/RecoveryMode_ForMountUpdate2.tpk

index e6f9bc65619ed0ee68be829e8b0485149b700e06..a00ffd6811610fc3b6435a49938185e05cd3bf2d 100644 (file)
@@ -656,6 +656,8 @@ TEST_F(SmokeTest, RecoveryMode_ForMountUpdate) {
 
   ASSERT_TRUE(ValidatePackage(pkgid, {appid, exec}, params));
   ASSERT_TRUE(ValidateFileContentInPackage(pkgid, "res/VERSION", "1", params));
+  ASSERT_TRUE(ValidateFileContentInPackage(pkgid, "shared/res/VERSION", "1",
+          params));
   ci::PkgQueryInterface pkg_query2(pkgid, params.test_user.uid, true);
   std::string version_recovered = pkg_query2.Version();
   ASSERT_TRUE(version_old == version_recovered);
@@ -685,6 +687,8 @@ TEST_F(RollbackSmokeTest, MountUpdateMode) {
 
   ASSERT_TRUE(ValidatePackage(pkgid, {appid, exec}, params));
   ASSERT_TRUE(ValidateFileContentInPackage(pkgid, "res/VERSION", "1", params));
+  ASSERT_TRUE(ValidateFileContentInPackage(pkgid, "shared/res/VERSION", "1",
+          params));
   ci::PkgQueryInterface pkg_query2(pkgid, params.test_user.uid, true);
   std::string version_rollbacked = pkg_query2.Version();
   ASSERT_TRUE(version_old == version_rollbacked);
index 9cbf1c0b523905dc0df6cf7ecb2578575f0e731b..6586b516dd38bf8072efff3c6339065af349238e 100644 (file)
Binary files a/src/unit_tests/test_samples/smoke/MountUpdateMode_Rollback.tpk and b/src/unit_tests/test_samples/smoke/MountUpdateMode_Rollback.tpk differ
index 2c35dfa7e21faf36344edafdfd3dcd4ec1bae51c..b8cb1f1a9eb08f5b3bb61a8c8fd4ba90d0be801a 100644 (file)
Binary files a/src/unit_tests/test_samples/smoke/MountUpdateMode_Rollback2.tpk and b/src/unit_tests/test_samples/smoke/MountUpdateMode_Rollback2.tpk differ
index 4b88c7209d1730a0e37dbaabf2247bede174dd91..b7f13cb05af07df0591b4ff93d4e3163af4290e7 100644 (file)
Binary files a/src/unit_tests/test_samples/smoke/RecoveryMode_ForMountUpdate.tpk and b/src/unit_tests/test_samples/smoke/RecoveryMode_ForMountUpdate.tpk differ
index e5e525d95dd4d06624dc474341704bb74c1a17fd..ef806863dc7aeb3349edb9a64957d908f50c4eea 100644 (file)
Binary files a/src/unit_tests/test_samples/smoke/RecoveryMode_ForMountUpdate2.tpk and b/src/unit_tests/test_samples/smoke/RecoveryMode_ForMountUpdate2.tpk differ