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

Side by Side Diff: client/deps/realtimecomm_playground/pgutil.py

Issue 2857032: Small fix in realtimecomm_playground test due to the local of options file has been changed. (Closed) Base URL: ssh://git@chromiumos-git/autotest.git
Patch Set: Update playground files. Created 10 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
« no previous file with comments | « client/deps/realtimecomm_playground/GTalkPlayground.tar.gz ('k') | 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 (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 os, shutil, time 5 import os, shutil, time
6 from autotest_lib.client.bin import test, utils 6 from autotest_lib.client.bin import test, utils
7 7
8 def get_pids(program_name): 8 def get_pids(program_name):
9 """ 9 """
10 Collect a list of pids for all the instances of a program. 10 Collect a list of pids for all the instances of a program.
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 Setup playground files. 59 Setup playground files.
60 60
61 @param src path 61 @param src path
62 @param dst path 62 @param dst path
63 @param optionfile 63 @param optionfile
64 """ 64 """
65 shutil.rmtree(dst, ignore_errors=True) 65 shutil.rmtree(dst, ignore_errors=True)
66 shutil.copytree(src, dst) 66 shutil.copytree(src, dst)
67 utils.run('chown chronos %s -R' % dst) 67 utils.run('chown chronos %s -R' % dst)
68 68
69 dst_path= '/home/chronos/.Google/' 69 dst_path= '/home/chronos/.config/'
70 opt_path= os.path.join(dst_path, 'Google Talk Plugin') 70 opt_path= os.path.join(dst_path, 'google-googletalkplugin')
71 dst_opt = os.path.join(opt_path, 'options') 71 dst_opt = os.path.join(opt_path, 'options')
72 utils.run('mkdir -p \'%s\'' % opt_path) 72 utils.run('mkdir -p \'%s\'' % opt_path)
73 utils.run('cp -f %s \'%s\'' % (optionfile, dst_opt)) 73 utils.run('cp -f %s \'%s\'' % (optionfile, dst_opt))
74 utils.run('chown chronos \'%s\' -R' % dst_path) 74 utils.run('chown chronos \'%s\' -R' % dst_path)
75 utils.run('chmod o+r+w \'%s\'' % dst_opt) 75 utils.run('chmod o+r+w \'%s\'' % dst_opt)
76 76
77 77
78 def cleanup_playground(playground, testdone=False): 78 def cleanup_playground(playground, testdone=False):
79 """ 79 """
80 Cleanup playground files. 80 Cleanup playground files.
81 81
82 @param playground path 82 @param playground path
83 @param testdone 83 @param testdone
84 """ 84 """
85 utils.run('pkill chrome', ignore_status=True) 85 utils.run('pkill chrome', ignore_status=True)
86 time.sleep(10) 86 time.sleep(10)
87 utils.run('pkill GoogleTalkPlugin', ignore_status=True) 87 utils.run('pkill GoogleTalkPlugin', ignore_status=True)
88 time.sleep(10) 88 time.sleep(10)
89 utils.run('rm -f /tmp/tmp.log', ignore_status=True) 89 utils.run('rm -f /tmp/tmp.log', ignore_status=True)
90 if testdone: 90 if testdone:
91 shutil.rmtree(playground) 91 shutil.rmtree(playground)
92 92
93 # Delete previous browser state if any 93 # Delete previous browser state if any
94 shutil.rmtree('/home/chronos/.config/chromium', ignore_errors=True) 94 shutil.rmtree('/home/chronos/.config/chromium', ignore_errors=True)
95 shutil.rmtree('/home/chronos/.config/google-chrome', ignore_errors=True) 95 shutil.rmtree('/home/chronos/.config/google-chrome', ignore_errors=True)
96 96
97 # Delete previous GTalk state if any
98 shutil.rmtree('/home/chronos/.config/google-googletalkplugin',
99 ignore_errors=True)
100
OLDNEW
« no previous file with comments | « client/deps/realtimecomm_playground/GTalkPlayground.tar.gz ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698