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

Side by Side Diff: client/site_tests/platform_ProcessPrivileges/platform_ProcessPrivileges.py

Issue 5740004: Move site_chrome_test, site_logging, site_log_reader, site_crash_test into cros dir. (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/autotest.git@master
Patch Set: patch Created 9 years, 11 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
OLDNEW
1 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. 1 # Copyright (c) 2010 The Chromium OS 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 time 5 import time
6 from autotest_lib.client.bin import utils 6 from autotest_lib.client.bin import utils
7 from autotest_lib.client.common_lib import error 7 from autotest_lib.client.common_lib import error
8 from autotest_lib.client.cros import ui_test 8 from autotest_lib.client.cros import cros_ui_test
9 9
10 class platform_ProcessPrivileges(ui_test.UITest): 10 class platform_ProcessPrivileges(cros_ui_test.UITest):
11 version = 1 11 version = 1
12 12
13 auto_login = False 13 auto_login = False
14 14
15 def log_error(self, process, command, message): 15 def log_error(self, process, command, message):
16 self.job.record('ERROR', None, command, message) 16 self.job.record('ERROR', None, command, message)
17 self._failed.append(process) 17 self._failed.append(process)
18 18
19 def check_process(self, process, user=None, do_login=False, grep_arg=None): 19 def check_process(self, process, user=None, do_login=False, grep_arg=None):
20 """Check if the process is running as the specified user / root. 20 """Check if the process is running as the specified user / root.
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 self.check_process('metrics_daemon', user='root') 85 self.check_process('metrics_daemon', user='root')
86 self.check_process('powerd') 86 self.check_process('powerd')
87 self.check_process('rsyslogd', user='root') 87 self.check_process('rsyslogd', user='root')
88 self.check_process('udevd', user='root') 88 self.check_process('udevd', user='root')
89 self.check_process('wpa_supplicant', user='root') 89 self.check_process('wpa_supplicant', user='root')
90 self.check_process('X', user='root') 90 self.check_process('X', user='root')
91 91
92 if len(self._failed) != 0: 92 if len(self._failed) != 0:
93 raise error.TestFail( 93 raise error.TestFail(
94 'Failed processes: %s' % ','.join(self._failed)) 94 'Failed processes: %s' % ','.join(self._failed))
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698