/frameworks/base/services/tests/servicestests/src/com/android/server/storage/ |
D | FileCollectorTest.java | 52 writeDataToFile(temporaryFolder.newFile("test.jpg"), "1234"); in testImageFile() 61 writeDataToFile(temporaryFolder.newFile("test.mp4"), "1234"); in testVideoFile() 70 writeDataToFile(temporaryFolder.newFile("test.mp3"), "1234"); in testAudioFile() 79 writeDataToFile(temporaryFolder.newFile("test"), "1234"); in testMiscFile() 98 writeDataToFile(temporaryFolder.newFile("test"), "1234"); in testMultipleFiles() 99 writeDataToFile(temporaryFolder.newFile("test2"), "12345"); in testMultipleFiles() 108 writeDataToFile(temporaryFolder.newFile("test.jpg"), "1"); in testTotalSize() 109 writeDataToFile(temporaryFolder.newFile("test.mp3"), "1"); in testTotalSize() 110 writeDataToFile(temporaryFolder.newFile("test.mp4"), "1"); in testTotalSize() 111 writeDataToFile(temporaryFolder.newFile("test"), "1"); in testTotalSize() [all …]
|
/frameworks/base/media/tests/MtpTests/src/android/mtp/ |
D | MtpStorageManagerTest.java | 79 private static void vWriteNewFile(File newFile) { in vWriteNewFile() argument 81 new FileOutputStream(newFile).write(new byte[] {0, 0, 0}); in vWriteNewFile() 190 File newFile = createNewFile(mainStorageDir); in testMtpObjectGetNameNonRoot() local 193 Assert.assertEquals(stream.get(0).getName(), newFile.getName()); in testMtpObjectGetNameNonRoot() 208 File newFile = createNewFile(mainStorageDir); in testMtpObjectGetIdNonRoot() local 226 File newFile = createNewFile(mainStorageDir, "TEST123.mp3"); in testMtpObjectIsDirFalse() local 236 File newFile = createNewDir(mainStorageDir); in testMtpObjectGetFormatDir() local 246 File newFile = createNewFile(mainStorageDir, "TEST123.mp3"); in testMtpObjectGetFormatNonDir() local 256 File newFile = createNewFile(mainStorageDir); in testMtpObjectGetStorageId() local 266 File newFile = createNewFile(mainStorageDir); in testMtpObjectGetLastModified() local [all …]
|
D | MtpDatabaseTest.java | 84 private static void writeNewFile(File newFile) { in writeNewFile() argument 86 new FileOutputStream(newFile).write(new byte[] {0, 0, 0}); in writeNewFile() 92 private static void writeNewFileFromByte(File newFile, byte[] byteData) { in writeNewFileFromByte() argument 94 new FileOutputStream(newFile).write(byteData); in writeNewFileFromByte()
|
/frameworks/base/packages/PackageInstaller/src/com/android/packageinstaller/wear/ |
D | WearPackageUtil.java | 46 File newFile = new File(newFileDir, packageName + ".apk"); in getTemporaryFile() local 47 return newFile; in getTemporaryFile() 80 File newFile = getTemporaryFile(context, packageName); in getFileFromFd() local 99 final FileOutputStream fo = new FileOutputStream(newFile); in getFileFromFd() 105 Os.chmod(newFile.getAbsolutePath(), 0644); in getFileFromFd() 106 return newFile; in getFileFromFd()
|
/frameworks/base/packages/SettingsLib/DataStore/tests/src/com/android/settingslib/datastore/ |
D | BackupRestoreStorageTest.kt | 149 temporaryFolder.newFile().toParcelFileDescriptor(MODE_READ_ONLY).use { in <lambda>() 160 temporaryFolder.newFile().toParcelFileDescriptor(MODE_READ_ONLY).use { in <lambda>() 170 temporaryFolder.newFile().toParcelFileDescriptor(MODE_READ_ONLY).use { in <lambda>() 206 temporaryFolder.newFile().toParcelFileDescriptor(MODE_READ_ONLY).use { in <lambda>() 217 temporaryFolder.newFile().toParcelFileDescriptor(MODE_READ_ONLY).apply { in <lambda>() 227 val stateFile = temporaryFolder.newFile() in <lambda>() 244 temporaryFolder.newFile().toParcelFileDescriptor(MODE_READ_ONLY).use { in <lambda>() 253 temporaryFolder.newFile().toParcelFileDescriptor(MODE_WRITE_ONLY or MODE_APPEND).use { in <lambda>() 286 val newStateFile = temporaryFolder.newFile() in <lambda>() 316 val stateFile = temporaryFolder.newFile() in <lambda>() [all …]
|
D | BackupRestoreFileArchiverTest.kt | 79 val file = temporaryFolder.newFile() in restoreEntity_disabled() 208 val file = temporaryFolder.newFile() in toBackupRestoreEntity_backup()
|
/frameworks/av/media/mtp/ |
D | MtpUtils.cpp | 144 string newFile = toPathStr + name; in copyRecursive() local 147 ret += makeFolder(newFile.c_str()); in copyRecursive() 148 ret += copyRecursive(oldFile.c_str(), newFile.c_str()); in copyRecursive() 150 ret += copyFile(oldFile.c_str(), newFile.c_str()); in copyRecursive()
|
/frameworks/base/core/tests/coretests/src/android/os/ |
D | MemoryFileTest.java | 69 MemoryFile newFile = new MemoryFile("MemoryFileTest", 10000000); in testPurge() local 70 newFile.allowPurging(true); in testPurge() 71 newFile.writeBytes(testString, 0, 0, testString.length); in testPurge() 72 files.add(newFile); in testPurge()
|
/frameworks/base/services/tests/PackageManagerServiceTests/host/src/com/android/server/pm/test/ |
D | TamperedUpdatedSystemPackageTest.kt | 93 val xml = tempFolder.newFile().apply { in backupAndModifySystemFiles() 126 tempFolder.newFile() in detectApkAndXmlTamperingAtBoot() 153 tempFolder.newFile() in detectApkTamperingAtBoot()
|
D | FactoryPackageTest.kt | 54 val versionTwoFile = HostUtils.copyResourceToHostFile(VERSION_TWO, tempFolder.newFile()) in testGetInstalledPackagesFactoryOnlyFlag() 67 val deviceSideFile = HostUtils.copyResourceToHostFile(DEVICE_SIDE, tempFolder.newFile()) in runDeviceTest()
|
D | InvalidNewSystemAppTest.kt | 69 val versionTwoFile = HostUtils.copyResourceToHostFile(VERSION_TWO, tempFolder.newFile()) in verify() 82 val versionFourFile = HostUtils.copyResourceToHostFile(VERSION_FOUR, tempFolder.newFile()) in verify()
|
D | PackageInstallerSessionTest.kt | 50 val deviceSideFile = HostUtils.copyResourceToHostFile(DEVICE_SIDE, tempFolder.newFile()) in runDeviceTest()
|
D | BootTest.kt | 42 val testApkFile = HostUtils.copyResourceToHostFile(TEST_APK_NAME, tempFolder.newFile()) in installApk()
|
D | SdCardEjectionTests.kt | 89 val hostApkFile = HostUtils.copyResourceToHostFile(VERSION_ONE, tempFolder.newFile()) in launchActivity() 120 val usesApkFile = HostUtils.copyResourceToHostFile(VERSION_USES, tempFolder.newFile()) in uninstallStaticLibraryInUse()
|
D | OverlayPathsUninstallSystemUpdatesTest.kt | 65 val versionTwoFile = HostUtils.copyResourceToHostFile(VERSION_TWO, tempFolder.newFile()) in verify()
|
D | OverlayActorVisibilityTest.kt | 72 val file = tempFolder.newFile().apply { in pushSysConfigFile()
|
D | OriginalPackageMigrationTest.kt | 88 val file = tempFolder.newFile().apply { writeText("Test") } in runForApk()
|
/frameworks/av/media/mtp/tests/MtpFuzzer/ |
D | mtp_fuzzer.cpp | 174 std::string newFile = toPathStr + name; in createDatabaseFromSourceDir() local 177 ret += makeFolder(newFile.c_str()); in createDatabaseFromSourceDir() 188 ret += createDatabaseFromSourceDir(oldFile.c_str(), newFile.c_str(), in createDatabaseFromSourceDir() 191 ret += copyFile(oldFile.c_str(), newFile.c_str()); in createDatabaseFromSourceDir()
|
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/backup/ |
D | PackageManagerBackupAgentTest.java | 89 mBackupData = folder.newFile("backup_data"); in setUp() 90 mOldState = folder.newFile("old_state"); in setUp() 91 mNewState = folder.newFile("new_state"); in setUp() 260 File temporaryBackupData = folder.newFile("backup_data.tmp"); in deleteKeyFromBackupData()
|
D | DataChangedJournalTest.java | 64 mFile = mTemporaryFolder.newFile(); in setUp() 104 assertThat(mJournal.equals(new DataChangedJournal(mTemporaryFolder.newFile()))).isFalse(); in equals_isFalseForDifferentFiles()
|
/frameworks/base/services/tests/PackageManagerServiceTests/unit/src/com/android/server/pm/test/verify/domain/ |
D | DomainVerificationPersistenceTest.kt | 118 val file = tempFolder.newFile().writeXml { in <lambda>() 137 val file = tempFolder.newFile().writeXml { in <lambda>() 166 val file = tempFolder.newFile().writeXml { in <lambda>()
|
D | DomainVerificationLegacySettingsTest.kt | 72 val file = tempFolder.newFile().writeXml(settings::writeSettings) in writeAndReadBackNormal()
|
/frameworks/base/services/tests/PackageManagerServiceTests/unit/src/com/android/server/pm/test/pkg/ |
D | PackageStateTest.kt | 121 .setCodePath(tempFolder.newFile().path) in collectionImmutability() 152 listOf(tempFolder.newFile().path), in fillMissingData() 165 listOf(tempFolder.newFile().path), in fillMissingData()
|
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/backup/utils/ |
D | BackupManagerMonitorDumpsysUtilsTest.java | 45 mTempBMMEventsFile = tmp.newFile("testbmmevents.txt"); in setUp() 46 mTempSetUpDateFile = tmp.newFile("testSetUpDate.txt"); in setUp()
|
D | DataStreamFileCodecTest.java | 44 File unicornFile = mTemporaryFolder.newFile(); in serialize_writesToTheFile()
|