| /cts/tests/tests/packageinstaller/install/src/android/packageinstaller/install/cts/ |
| D | InstallInfoTest.kt | 91 val apk = tempFolder.newFile(NOT_AN_APK).apply { in <lambda>() 101 val apk = tempFolder.newFile(CORRUPTED_APK_NAME) in <lambda>() 114 val apk = tempFolder.newFile(NOT_AN_APK).apply { in <lambda>()
|
| /cts/hostsidetests/scopedstorage/device/src/android/scopedstorage/cts/device/ |
| D | OtherAppFilesRule.java | 139 private Uri createFileAsOther(File buffer, File newFile) in createFileAsOther() argument 142 Log.d(TAG, "Creating file " + newFile); in createFileAsOther() 143 assertThat(createFileAs(APP_D_LEGACY_HAS_RW, newFile.getAbsolutePath(), in createFileAsOther() 145 final Uri mediaUri = MediaStore.scanFile(mContentResolver, newFile); in createFileAsOther()
|
| /cts/hostsidetests/packagemanager/parsing/processing/api/src/android/content/pm/parsing/cts/generator/api/ |
| D | ApkGenerator.kt | 76 return tempFolder.newFile().apply { in <lambda>() 90 val outputFile = tempFolder.newFile() in <lambda>()
|
| /cts/tests/tests/os/src/android/os/cts/ |
| D | FileAccessPermissionTest.java | 115 File newFile = new File(dir, System.currentTimeMillis() + "test.txt"); in testAccessAppDataDir() local 117 assertTrue(newFile.createNewFile()); in testAccessAppDataDir() 118 writeFileCheck(newFile); in testAccessAppDataDir()
|
| /cts/hostsidetests/packagemanager/domainverification/host/src/com/android/cts/packagemanager/verify/domain/host/ |
| D | DomainVerificationHostUtils.kt | 33 copyResourceToHostFile(apkName.value, tempFolder.newFile()), in <lambda>()
|
| /cts/hostsidetests/appsecurity/test-apps/MediaStorageApp/src/com/android/cts/mediastorageapp/ |
| D | MediaStorageTest.java | 681 final File newFile = Environment.buildPath( in assertRenameFileAPISupport() local 685 final String newName = newFile.getAbsolutePath(); in assertRenameFileAPISupport() 687 .that(oldFile.renameTo(newFile)) in assertRenameFileAPISupport() 691 .that(newFile.renameTo(oldFile)) in assertRenameFileAPISupport() 702 File newFile = new File(queryForSingleColumn(newUri, MediaColumns.DATA)); in assertRenameAndReplaceFileAPISupport() local 703 final String newName = newFile.getAbsolutePath(); in assertRenameAndReplaceFileAPISupport() 709 .that(oldFile.renameTo(newFile)) in assertRenameAndReplaceFileAPISupport() 716 .that(oldFile.renameTo(newFile)) in assertRenameAndReplaceFileAPISupport() 725 .that(newFile.renameTo(oldFile)) in assertRenameAndReplaceFileAPISupport()
|
| /cts/hostsidetests/scopedstorage/src/android/scopedstorage/cts/ |
| D | ScopedStorageTest.java | 915 private void assertCreateFileAndScanNomediaDirDoesntNoOp(File newFile, File scanDir) in assertCreateFileAndScanNomediaDirDoesntNoOp() argument 917 assertThat(newFile.createNewFile()).isTrue(); in assertCreateFileAndScanNomediaDirDoesntNoOp() 920 assertThat(getFileRowIdFromDatabase(newFile)).isEqualTo(-1); in assertCreateFileAndScanNomediaDirDoesntNoOp() 923 assertThat(getFileRowIdFromDatabase(newFile)).isNotEqualTo(-1); in assertCreateFileAndScanNomediaDirDoesntNoOp() 1223 private void createAndCheckFileAsApp(TestApp testApp, File newFile) throws Exception { in createAndCheckFileAsApp() argument 1224 assertThat(createFileAs(testApp, newFile.getPath())).isTrue(); in createAndCheckFileAsApp() 1225 assertThat(getFileOwnerPackageFromDatabase(newFile)) in createAndCheckFileAsApp() 1227 assertThat(getFileRowIdFromDatabase(newFile)).isNotEqualTo(-1); in createAndCheckFileAsApp()
|
| /cts/hostsidetests/scopedstorage/libs/ScopedStorageTestLib/src/android/scopedstorage/cts/lib/ |
| D | TestUtils.java | 1229 public static void assertCanRenameFile(File oldFile, File newFile) { in assertCanRenameFile() argument 1230 assertCanRenameFile(oldFile, newFile, /* checkDB */ true); in assertCanRenameFile() 1236 public static void assertCanRenameFile(File oldFile, File newFile, boolean checkDatabase) { in assertCanRenameFile() argument 1237 assertThat(oldFile.renameTo(newFile)).isTrue(); in assertCanRenameFile() 1239 assertThat(newFile.exists()).isTrue(); in assertCanRenameFile() 1242 assertThat(getFileRowIdFromDatabase(newFile)).isNotEqualTo(-1); in assertCanRenameFile() 1249 public static void assertCantRenameFile(File oldFile, File newFile) { in assertCantRenameFile() argument 1251 assertThat(oldFile.renameTo(newFile)).isFalse(); in assertCantRenameFile()
|
| /cts/hostsidetests/scopedstorage/legacy/src/android/scopedstorage/cts/legacy/ |
| D | LegacyStorageTest.java | 342 final File newFile = new File(TestUtils.getMusicDir(), "LegacyStorageTest.mp3"); in testReadOnlyExternalStorage_hasR() local 344 newFile.createNewFile(); in testReadOnlyExternalStorage_hasR() 345 fail("Creating file expected to fail: " + newFile); in testReadOnlyExternalStorage_hasR()
|
| /cts/hostsidetests/scopedstorage/general/src/android/scopedstorage/cts/general/ |
| D | ScopedStorageDeviceTest.java | 1087 File newFile = new File(getDcimDir(), newDisplayName); in testContentResolverUpdate() local 1108 assertThat(newFile.exists()).isTrue(); in testContentResolverUpdate() 1109 assertThat(newFile.createNewFile()).isFalse(); in testContentResolverUpdate() 1115 newFile.delete(); in testContentResolverUpdate() 3233 final File newFile = new File(file.getAbsolutePath(), "test"); in testTransformsDirCommon() local 3234 assertThat(newFile.mkdir()).isFalse(); in testTransformsDirCommon() 3235 assertThrows(IOException.class, () -> newFile.createNewFile()); in testTransformsDirCommon()
|