Home
last modified time | relevance | path

Searched refs:downloadUri (Results 1 – 6 of 6) sorted by relevance

/cts/tests/app/DownloadManagerApi28Test/src/android/app/cts/
DDownloadManagerApi28Test.java151 final Uri downloadUri = mDownloadManager.getUriForDownloadedFile(id); in testAddCompletedDownload_publicDirs() local
152 mContext.grantUriPermission("com.android.shell", downloadUri, in testAddCompletedDownload_publicDirs()
154 final String rawFilePath = getRawFilePath(downloadUri); in testAddCompletedDownload_publicDirs()
182 final Uri downloadUri = mDownloadManager.getUriForDownloadedFile(downloadId); in testDownloadManager_mediaStoreEntry() local
183 final Uri mediaStoreUri = getMediaStoreUri(downloadUri); in testDownloadManager_mediaStoreEntry()
185 assertArrayEquals(hash(contentResolver.openInputStream(downloadUri)), in testDownloadManager_mediaStoreEntry()
231 final Uri downloadUri = mDownloadManager.getUriForDownloadedFile(downloadId); in testAddCompletedDownload_mediaStoreEntry() local
232 final Uri mediaStoreUri = getMediaStoreUri(downloadUri); in testAddCompletedDownload_mediaStoreEntry()
/cts/tests/tests/provider/src/android/provider/cts/media/
DMediaStore_DownloadsTest.java184 final Uri downloadUri = Uri.parse("https://developer.android.com/overview.html"); in testInsertDownload() local
189 params.setDownloadUri(downloadUri); in testInsertDownload()
213 assertEquals(downloadUri.toString(), in testInsertDownload()
235 final Uri downloadUri = Uri.parse("https://www.android.com/download?file=testvideo.3gp"); in testUpdateDownload() local
236 params.setDownloadUri(downloadUri); in testUpdateDownload()
261 assertEquals(downloadUri.toString(), in testUpdateDownload()
271 final Uri downloadUri = Uri.parse("https://www.android.com/download?file=testvideo.3gp"); in testDeleteDownload() local
272 params.setDownloadUri(downloadUri); in testDeleteDownload()
312 final Uri downloadUri = Uri.parse("https://www.android.com/download?file=testvideo.3gp"); in testNotifyChange() local
313 params.setDownloadUri(downloadUri); in testNotifyChange()
DMediaStoreUtils.java127 public void setDownloadUri(@Nullable Uri downloadUri) { in setDownloadUri() argument
128 if (downloadUri == null) { in setDownloadUri()
131 this.insertValues.put(DownloadColumns.DOWNLOAD_URI, downloadUri.toString()); in setDownloadUri()
/cts/hostsidetests/appsecurity/test-apps/MediaStorageApp/src/com/android/cts/mediastorageapp/
DMediaStoreUtils.java118 public void setDownloadUri(@Nullable Uri downloadUri) { in setDownloadUri() argument
119 if (downloadUri == null) { in setDownloadUri()
122 this.insertValues.put(DownloadColumns.DOWNLOAD_URI, downloadUri.toString()); in setDownloadUri()
/cts/tests/app/src/android/app/cts/
DDownloadManagerTest.java536 final Uri downloadUri = mDownloadManager.getUriForDownloadedFile(id); in testAddCompletedDownload() local
537 mContext.grantUriPermission("com.android.shell", downloadUri, in testAddCompletedDownload()
539 final String rawFilePath = getRawFilePath(downloadUri); in testAddCompletedDownload()
560 final Uri downloadUri = mDownloadManager.getUriForDownloadedFile(id); in testAddCompletedDownload_downloadDir() local
561 mContext.grantUriPermission("com.android.shell", downloadUri, in testAddCompletedDownload_downloadDir()
563 final String rawFilePath = getRawFilePath(downloadUri); in testAddCompletedDownload_downloadDir()
680 final Uri downloadUri = mDownloadManager.getUriForDownloadedFile(id); in testDownload_mediaScanned() local
681 mContext.grantUriPermission("com.android.shell", downloadUri, in testDownload_mediaScanned()
683 final Uri mediaStoreUri = getMediaStoreUri(downloadUri); in testDownload_mediaScanned()
687 mContext.getContentResolver().openInputStream(downloadUri)); in testDownload_mediaScanned()
DDownloadManagerTestBase.java145 protected static Uri getMediaStoreUri(Uri downloadUri) throws Exception { in getMediaStoreUri() argument
147 Cursor cursor = context.getContentResolver().query(downloadUri, null, null, null); in getMediaStoreUri()
155 throw new FileNotFoundException("Failed to find entry for " + downloadUri); in getMediaStoreUri()