Home
last modified time | relevance | path

Searched refs:testFile (Results 1 – 11 of 11) sorted by relevance

/tools/tradefederation/core/tests/src/com/android/tradefed/util/
DFileUtilTest.java58 File testFile = null; in testChmodGroupRW() local
64 testFile = FileUtil.createTempFile("testChmodRW", ".txt"); in testChmodGroupRW()
65 assertTrue(FileUtil.chmodGroupRW(testFile)); in testChmodGroupRW()
66 assertTrue(testFile.canRead()); in testChmodGroupRW()
67 assertTrue(testFile.canWrite()); in testChmodGroupRW()
68 assertFalse(testFile.canExecute()); in testChmodGroupRW()
70 FileUtil.deleteFile(testFile); in testChmodGroupRW()
80 File testFile = null; in testChmodGroupRW_noChmod() local
83 testFile = FileUtil.createTempFile("testChmodRW", ".txt"); in testChmodGroupRW_noChmod()
84 assertTrue(FileUtil.chmodGroupRW(testFile)); in testChmodGroupRW_noChmod()
[all …]
DTarUtilTest.java61 File testFile = TarUtil.unGzip(logTarGzFile, mWorkDir); in testUnGzip() local
62 Assert.assertTrue(testFile.exists()); in testUnGzip()
66 Assert.assertEquals(expectedName, testFile.getName()); in testUnGzip()
81 File testFile = TarUtil.unGzip(logTarGzFile, mWorkDir); in testUntar() local
82 Assert.assertTrue(testFile.exists()); in testUntar()
83 List<File> untaredList = TarUtil.unTar(testFile, mWorkDir); in testUntar()
DFileUtilFuncTest.java352 File testFile = FileUtil.createTempFile("test", "file", subdir1); in testRecursiveSymlink() local
356 assertNotNull(FileUtil.findFile(dest, testFile.getName())); in testRecursiveSymlink()
373 File testFile = FileUtil.createTempFile("test", "file", subdir1); in testSymlinkDeletion() local
378 assertNotNull(FileUtil.findFile(dest, testFile.getName())); in testSymlinkDeletion()
/tools/tradefederation/core/tests/src/com/android/tradefed/targetprep/
DInstallApkSetupTest.java48 private File testFile = null; field in InstallApkSetupTest
60 testFile = FileUtil.createTempFile("File", ".apk", testDir); in setUp()
74 testCollectionFiles.add(testFile); in testSetup()
75 testCollectionFiles.add(testFile); in testSetup()
89 testCollectionFiles.add(testFile); in testNonExistingApk()
90 FileUtil.recursiveDelete(testFile); in testNonExistingApk()
97 String refMessage = String.format("%s does not exist null", testFile.getAbsolutePath()); in testNonExistingApk()
110 testCollectionFiles.add(testFile); in testInstallFailureNoThrow()
115 testFile.getAbsolutePath())).times(1); in testInstallFailureNoThrow()
127 testCollectionFiles.add(testFile); in testInstallFailureThrow()
[all …]
/tools/tradefederation/core/src/com/android/tradefed/testtype/
DInstrumentationFileTest.java133 File testFile = null; in writeTestsToFileAndRun() local
136 testFile = FileUtil.createTempFile( in writeTestsToFileAndRun()
138 try (BufferedWriter bw = new BufferedWriter(new FileWriter(testFile))) { in writeTestsToFileAndRun()
152 CLog.d("Test file %s was successfully created", testFile.getAbsolutePath()); in writeTestsToFileAndRun()
155 mFilePathOnDevice = ON_DEVICE_TEST_DIR_LOCATION + testFile.getName(); in writeTestsToFileAndRun()
156 if (pushFileToTestDevice(testFile, mFilePathOnDevice)) { in writeTestsToFileAndRun()
159 testFile.getAbsolutePath(), mFilePathOnDevice); in writeTestsToFileAndRun()
179 FileUtil.deleteFile(testFile); in writeTestsToFileAndRun()
DITestFileFilterReceiver.java36 void setIncludeTestFile(File testFile); in setIncludeTestFile() argument
41 void setExcludeTestFile(File testFile); in setExcludeTestFile() argument
DAndroidJUnitTest.java195 public void setIncludeTestFile(File testFile) { in setIncludeTestFile() argument
196 mIncludeTestFile = testFile; in setIncludeTestFile()
203 public void setExcludeTestFile(File testFile) { in setExcludeTestFile() argument
204 mExcludeTestFile = testFile; in setExcludeTestFile()
352 private void pushTestFile(File testFile, String destination, ITestInvocationListener listener) in pushTestFile() argument
354 if (!testFile.canRead() || !testFile.isFile()) { in pushTestFile()
355 String message = String.format("Cannot read test file %s", testFile.getAbsolutePath()); in pushTestFile()
361 if (!device.pushFile(testFile, destination)) { in pushTestFile()
365 testFile.getAbsolutePath(), destination, device.getSerialNumber()); in pushTestFile()
/tools/tradefederation/core/tests/src/com/android/tradefed/build/
DBuildInfoTest.java128 File testFile = FileUtil.createTempFile("fake-versioned-file", ".txt"); in testCleanUpWithExemption() local
131 mBuildInfo.setFile("name", testFile, "version"); in testCleanUpWithExemption()
143 FileUtil.deleteFile(testFile); in testCleanUpWithExemption()
DLocalDeviceBuildProviderTest.java178 File testFile = new File(mTestDir, "some-test"); in testSetTestsDir_givenTestDir() local
179 FileUtil.writeToFile("tests", testFile); in testSetTestsDir_givenTestDir()
184 File extractedTestFile = new File(testDir, testFile.getName()); in testSetTestsDir_givenTestDir()
186 assertTrue(FileUtil.compareFileContents(testFile, extractedTestFile)); in testSetTestsDir_givenTestDir()
/tools/tradefederation/core/tests/src/com/android/tradefed/invoker/
DShardListenerTest.java160 LogFile testFile = new LogFile("path", "url", false, LogDataType.TEXT, 0L); in testLogOrderingForSharding() local
166 .andReturn(testFile); in testLogOrderingForSharding()
171 EasyMock.eq(testFile)); in testLogOrderingForSharding()
177 mockListener.logAssociation("test-file", testFile); in testLogOrderingForSharding()
/tools/tradefederation/core/src/com/android/tradefed/device/
DNativeDeviceStateMonitor.java287 final String testFile = String.format("'%s/%d'", externalStore, number); in waitForStoreMount() local
289 final String writeCmd = String.format("echo '%s' > %s", testString, testFile); in waitForStoreMount()
290 final String checkCmd = String.format("cat %s", testFile); in waitForStoreMount()
291 final String cleanupCmd = String.format("rm %s", testFile); in waitForStoreMount()