mirror of
https://github.com/f-droid/fdroidclient.git
synced 2026-06-18 12:49:59 -04:00
Add apps with known vulnerabilities to updates tab.
Currently only supports "Uninstall", but will soon also support "Upgrade to a newer version".
This commit is contained in:
@@ -21,6 +21,7 @@ import org.fdroid.fdroid.data.ApkProvider;
|
||||
import org.fdroid.fdroid.data.App;
|
||||
import org.fdroid.fdroid.data.AppProvider;
|
||||
import org.fdroid.fdroid.data.FDroidProviderTest;
|
||||
import org.fdroid.fdroid.data.InstalledAppTestUtils;
|
||||
import org.fdroid.fdroid.data.Repo;
|
||||
import org.fdroid.fdroid.data.RepoProvider;
|
||||
import org.fdroid.fdroid.data.RepoPushRequest;
|
||||
@@ -121,6 +122,12 @@ public class IndexV1UpdaterTest extends FDroidProviderTest {
|
||||
assertEquals("repo.mirrors should have items", 2, repo.mirrors.length);
|
||||
assertEquals("repo.mirrors first URL", "http://frkcchxlcvnb4m5a.onion/fdroid/repo", repo.mirrors[0]);
|
||||
assertEquals("repo.mirrors second URL", "http://testy.at.or.at/fdroid/repo", repo.mirrors[1]);
|
||||
|
||||
// Make sure the per-apk anti features which are new in index v1 get added correctly.
|
||||
assertEquals(0, AppProvider.Helper.findInstalledAppsWithKnownVulns(context).size());
|
||||
InstalledAppTestUtils.install(context, "com.waze", 1019841, "v3.9.5.4", "362488e7be5ea0689b4e97d989ae1404",
|
||||
"cbbdb8c5dafeccd7dd7b642dde0477d3489e18ac366e3c8473d5c07e5f735a95");
|
||||
assertEquals(1, AppProvider.Helper.findInstalledAppsWithKnownVulns(context).size());
|
||||
}
|
||||
|
||||
@Test(expected = RepoUpdater.SigningException.class)
|
||||
|
||||
Reference in New Issue
Block a user