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

Side by Side Diff: ios/build/bots/scripts/test_runner.py

Issue 2782023002: Change --gtest-filter argument to --gtest_filter (Closed)
Patch Set: Created 3 years, 8 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2016 The Chromium Authors. All rights reserved. 1 # Copyright 2016 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 """Test runners for iOS.""" 5 """Test runners for iOS."""
6 6
7 import argparse 7 import argparse
8 import collections 8 import collections
9 import errno 9 import errno
10 import os 10 import os
(...skipping 733 matching lines...) Expand 10 before | Expand all | Expand 10 after
744 'idevice-app-runner', 744 'idevice-app-runner',
745 '--udid', self.udid, 745 '--udid', self.udid,
746 '--start', self.cfbundleid, 746 '--start', self.cfbundleid,
747 ] 747 ]
748 args = [] 748 args = []
749 749
750 if test_filter: 750 if test_filter:
751 kif_filter = get_kif_test_filter(test_filter, invert=invert) 751 kif_filter = get_kif_test_filter(test_filter, invert=invert)
752 gtest_filter = get_gtest_filter(test_filter, invert=invert) 752 gtest_filter = get_gtest_filter(test_filter, invert=invert)
753 cmd.extend(['-D', 'GKIF_SCENARIO_FILTER=%s' % kif_filter]) 753 cmd.extend(['-D', 'GKIF_SCENARIO_FILTER=%s' % kif_filter])
754 args.append('--gtest-filter=%s' % gtest_filter) 754 args.append('--gtest_filter=%s' % gtest_filter)
755 755
756 for env_var in self.env_vars: 756 for env_var in self.env_vars:
757 cmd.extend(['-D', env_var]) 757 cmd.extend(['-D', env_var])
758 758
759 if args or self.test_args: 759 if args or self.test_args:
760 cmd.append('--args') 760 cmd.append('--args')
761 cmd.extend(self.test_args) 761 cmd.extend(self.test_args)
762 cmd.extend(args) 762 cmd.extend(args)
763 763
764 return cmd 764 return cmd
765 765
766 def get_launch_env(self): 766 def get_launch_env(self):
767 """Returns a dict of environment variables to use to launch the test app. 767 """Returns a dict of environment variables to use to launch the test app.
768 768
769 Returns: 769 Returns:
770 A dict of environment variables. 770 A dict of environment variables.
771 """ 771 """
772 env = super(DeviceTestRunner, self).get_launch_env() 772 env = super(DeviceTestRunner, self).get_launch_env()
773 if self.xctest_path: 773 if self.xctest_path:
774 env['NSUnbufferedIO'] = 'YES' 774 env['NSUnbufferedIO'] = 'YES'
775 # e.g. ios_web_shell_egtests 775 # e.g. ios_web_shell_egtests
776 env['APP_TARGET_NAME'] = os.path.splitext( 776 env['APP_TARGET_NAME'] = os.path.splitext(
777 os.path.basename(self.app_path))[0] 777 os.path.basename(self.app_path))[0]
778 # e.g. ios_web_shell_egtests_module 778 # e.g. ios_web_shell_egtests_module
779 env['TEST_TARGET_NAME'] = env['APP_TARGET_NAME'] + '_module' 779 env['TEST_TARGET_NAME'] = env['APP_TARGET_NAME'] + '_module'
780 return env 780 return env
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698