Second app_install attempt should succeeed
authorKrzysztof Jackiewicz <k.jackiewicz@samsung.com>
Tue, 7 May 2013 08:28:13 +0000 (10:28 +0200)
committerMarcin Niesluchowski <m.niesluchow@samsung.com>
Thu, 23 Jan 2014 13:19:16 +0000 (14:19 +0100)
[Issue#] N/A
[Problem] Test fails since multiple app_install calls have been allowed
[Cause] Test was not updated
[Solution] Test updated

[Verification] libprivilege-control-test --regexp=app_install

Change-Id: I23ee02848e43001376b90f50d3e746d9d56f119d

tests/libprivilege-control-tests/test_cases.cpp

index c786078..cbe8027 100644 (file)
@@ -888,9 +888,9 @@ RUNNER_TEST(privilege_control01_app_install)
     close(fd);
     free(path);
 
-    // try install second time app with the same ID - it should failed with -1 (Errno: File exists).
+    // try install second time app with the same ID - it should pass.
     result = app_install(APP_ID);
-    RUNNER_ASSERT_MSG(result == -1, "app_install returned " << result <<". Errno: " << strerror(errno));
+    RUNNER_ASSERT_MSG(result == 0, "app_install returned " << result <<". Errno: " << strerror(errno));
 }
 
 /*