Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(77)

Side by Side Diff: build/android/pylib/single_test_runner.py

Issue 10896050: Android: Use external storage for test data. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « build/android/pylib/constants.py ('k') | build/android/pylib/test_package_apk.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import glob 5 import glob
6 import logging 6 import logging
7 import os 7 import os
8 import sys 8 import sys
9 9
10 from base_test_runner import BaseTestRunner 10 from base_test_runner import BaseTestRunner
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 if self._TestSuiteRequiresMockTestServer(): 245 if self._TestSuiteRequiresMockTestServer():
246 self.LaunchChromeTestServerSpawner() 246 self.LaunchChromeTestServerSpawner()
247 247
248 def StripAndCopyFiles(self): 248 def StripAndCopyFiles(self):
249 """Strips and copies the required data files for the test suite.""" 249 """Strips and copies the required data files for the test suite."""
250 self.test_package.StripAndCopyExecutable() 250 self.test_package.StripAndCopyExecutable()
251 self.test_package.PushDataAndPakFiles() 251 self.test_package.PushDataAndPakFiles()
252 self.tool.CopyFiles() 252 self.tool.CopyFiles()
253 test_data = self.GetDataFilesForTestSuite() 253 test_data = self.GetDataFilesForTestSuite()
254 if test_data and not self.fast_and_loose: 254 if test_data and not self.fast_and_loose:
255 # Due to the large size of certain test data, we use sdcard to store the 255 # Make sure SD card is ready.
256 # test data and create symbolic links to map them to data/local/tmp/.
257 # Before that, make sure SD card is ready.
258 self.adb.WaitForSdCardReady(20) 256 self.adb.WaitForSdCardReady(20)
259 for data in test_data: 257 for data in test_data:
260 self.CopyTestData([data], '/sdcard/') 258 self.CopyTestData([data], constants.TEST_DATA_DIR)
261 self.LinkSdCardPathsToTempDir(test_data)
262 259
263 def RunTestsWithFilter(self): 260 def RunTestsWithFilter(self):
264 """Runs a tests via a small, temporary shell script.""" 261 """Runs a tests via a small, temporary shell script."""
265 self.test_package.CreateTestRunnerScript(self._gtest_filter, 262 self.test_package.CreateTestRunnerScript(self._gtest_filter,
266 self._test_arguments) 263 self._test_arguments)
267 self.test_results = self.test_package.RunTestsAndListResults() 264 self.test_results = self.test_package.RunTestsAndListResults()
268 265
269 def RebaselineTests(self): 266 def RebaselineTests(self):
270 """Runs all available tests, restarting in case of failures.""" 267 """Runs all available tests, restarting in case of failures."""
271 if self._gtest_filter: 268 if self._gtest_filter:
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
332 self.tool.CleanUpEnvironment() 329 self.tool.CleanUpEnvironment()
333 if self.test_package.cleanup_test_files: 330 if self.test_package.cleanup_test_files:
334 self.adb.RemovePushedFiles() 331 self.adb.RemovePushedFiles()
335 if self.dump_debug_info: 332 if self.dump_debug_info:
336 self.dump_debug_info.StopRecordingLog() 333 self.dump_debug_info.StopRecordingLog()
337 if self.test_package.performance_test: 334 if self.test_package.performance_test:
338 self.adb.TearDownPerformanceTest() 335 self.adb.TearDownPerformanceTest()
339 if self.dump_debug_info: 336 if self.dump_debug_info:
340 self.dump_debug_info.ArchiveNewCrashFiles() 337 self.dump_debug_info.ArchiveNewCrashFiles()
341 super(SingleTestRunner, self).TearDown() 338 super(SingleTestRunner, self).TearDown()
OLDNEW
« no previous file with comments | « build/android/pylib/constants.py ('k') | build/android/pylib/test_package_apk.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698