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

Side by Side Diff: sky/tools/webkitpy/layout_tests/port/android.py

Issue 1215953006: Use sky_shell instead of mojo_shell for testing. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Foo Created 5 years, 5 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
OLDNEW
1 # Copyright (C) 2012 Google Inc. All rights reserved. 1 # Copyright (C) 2012 Google Inc. All rights reserved.
2 # 2 #
3 # Redistribution and use in source and binary forms, with or without 3 # Redistribution and use in source and binary forms, with or without
4 # modification, are permitted provided that the following conditions are 4 # modification, are permitted provided that the following conditions are
5 # met: 5 # met:
6 # 6 #
7 # * Redistributions of source code must retain the above copyright 7 # * Redistributions of source code must retain the above copyright
8 # notice, this list of conditions and the following disclaimer. 8 # notice, this list of conditions and the following disclaimer.
9 # * Redistributions in binary form must reproduce the above 9 # * Redistributions in binary form must reproduce the above
10 # copyright notice, this list of conditions and the following disclaimer 10 # copyright notice, this list of conditions and the following disclaimer
(...skipping 408 matching lines...) Expand 10 before | Expand all | Expand 10 after
419 419
420 self._operating_system = 'android' 420 self._operating_system = 'android'
421 self._version = 'icecreamsandwich' 421 self._version = 'icecreamsandwich'
422 422
423 self._host_port = factory.PortFactory(host).get('chromium', **kwargs) 423 self._host_port = factory.PortFactory(host).get('chromium', **kwargs)
424 self._server_process_constructor = self._android_server_process_construc tor 424 self._server_process_constructor = self._android_server_process_construc tor
425 425
426 if not self.get_option('disable_breakpad'): 426 if not self.get_option('disable_breakpad'):
427 self._dump_reader = DumpReaderAndroid(host, self._build_path()) 427 self._dump_reader = DumpReaderAndroid(host, self._build_path())
428 428
429 if self.driver_name() != self.CONTENT_SHELL_NAME:
430 raise AssertionError('Layout tests on Android only support content_s hell as the driver.')
431
432 self._driver_details = ContentShellDriverDetails() 429 self._driver_details = ContentShellDriverDetails()
433 430
434 # Initialize the AndroidDevices class which tracks available devices. 431 # Initialize the AndroidDevices class which tracks available devices.
435 default_device = None 432 default_device = None
436 if hasattr(self._options, 'adb_device') and len(self._options.adb_device ): 433 if hasattr(self._options, 'adb_device') and len(self._options.adb_device ):
437 default_device = self._options.adb_device 434 default_device = self._options.adb_device
438 435
439 self._debug_logging = self.get_option('android_logging') 436 self._debug_logging = self.get_option('android_logging')
440 self._devices = AndroidDevices(self._executive, default_device, self._de bug_logging) 437 self._devices = AndroidDevices(self._executive, default_device, self._de bug_logging)
441 438
(...skipping 11 matching lines...) Expand all
453 # Local public methods. 450 # Local public methods.
454 def path_to_forwarder(self): 451 def path_to_forwarder(self):
455 return self._build_path('forwarder') 452 return self._build_path('forwarder')
456 453
457 def path_to_md5sum(self): 454 def path_to_md5sum(self):
458 return self._build_path(MD5SUM_DEVICE_FILE_NAME) 455 return self._build_path(MD5SUM_DEVICE_FILE_NAME)
459 456
460 def path_to_md5sum_host(self): 457 def path_to_md5sum_host(self):
461 return self._build_path(MD5SUM_HOST_FILE_NAME) 458 return self._build_path(MD5SUM_HOST_FILE_NAME)
462 459
463 def additional_drt_flag(self):
464 return self._driver_details.additional_command_line_flags(use_breakpad=n ot self.get_option('disable_breakpad'))
465
466 def default_timeout_ms(self): 460 def default_timeout_ms(self):
467 # Android platform has less computing power than desktop platforms. 461 # Android platform has less computing power than desktop platforms.
468 # Using 10 seconds allows us to pass most slow tests which are not 462 # Using 10 seconds allows us to pass most slow tests which are not
469 # marked as slow tests on desktop platforms. 463 # marked as slow tests on desktop platforms.
470 return 10 * 1000 464 return 10 * 1000
471 465
472 def driver_stop_timeout(self): 466 def driver_stop_timeout(self):
473 # The driver doesn't respond to closing stdin, so we might as well stop the driver immediately. 467 # The driver doesn't respond to closing stdin, so we might as well stop the driver immediately.
474 return 0.0 468 return 0.0
475 469
(...skipping 792 matching lines...) Expand 10 before | Expand all | Expand 10 after
1268 return command 1262 return command
1269 1263
1270 def _read_prompt(self, deadline): 1264 def _read_prompt(self, deadline):
1271 last_char = '' 1265 last_char = ''
1272 while True: 1266 while True:
1273 current_char = self._server_process.read_stdout(deadline, 1) 1267 current_char = self._server_process.read_stdout(deadline, 1)
1274 if current_char == ' ': 1268 if current_char == ' ':
1275 if last_char in ('#', '$'): 1269 if last_char in ('#', '$'):
1276 return 1270 return
1277 last_char = current_char 1271 last_char = current_char
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698