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

Side by Side Diff: client/bin/partition.py

Issue 3554003: Merge remote branch 'cros/upstream' into tempbranch3 (Closed) Base URL: http://git.chromium.org/git/autotest.git
Patch Set: Created 10 years, 2 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 | « client/bin/kernel_unittest.py ('k') | client/common_lib/log.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 """ 1 """
2 APIs to write tests and control files that handle partition creation, deletion 2 APIs to write tests and control files that handle partition creation, deletion
3 and formatting. 3 and formatting.
4 4
5 @copyright: Google 2006-2008 5 @copyright: Google 2006-2008
6 @author: Martin Bligh (mbligh@google.com) 6 @author: Martin Bligh (mbligh@google.com)
7 """ 7 """
8 8
9 import os, re, string, sys, fcntl, logging 9 import os, re, string, sys, fcntl, logging
10 from autotest_lib.client.bin import os_dep, utils 10 from autotest_lib.client.bin import os_dep, utils
(...skipping 620 matching lines...) Expand 10 before | Expand all | Expand 10 after
631 except: 631 except:
632 if record: 632 if record:
633 self.job.record('FAIL', None, fsck_cmd, error.format_error()) 633 self.job.record('FAIL', None, fsck_cmd, error.format_error())
634 raise error.TestError('Fsck found errors with the underlying ' 634 raise error.TestError('Fsck found errors with the underlying '
635 'file system') 635 'file system')
636 else: 636 else:
637 if record: 637 if record:
638 self.job.record('GOOD', None, fsck_cmd) 638 self.job.record('GOOD', None, fsck_cmd)
639 639
640 640
641 def mount(self, mountpoint, fstype=None, args='', record=True): 641 def mount(self, mountpoint=None, fstype=None, args='', record=True):
642 """ 642 """
643 Mount this partition to a mount point 643 Mount this partition to a mount point
644 644
645 @param mountpoint: If you have not provided a mountpoint to partition 645 @param mountpoint: If you have not provided a mountpoint to partition
646 object or want to use a different one, you may specify it here. 646 object or want to use a different one, you may specify it here.
647 @param fstype: Filesystem type. If not provided partition object value 647 @param fstype: Filesystem type. If not provided partition object value
648 will be used. 648 will be used.
649 @param args: Arguments to be passed to "mount" command. 649 @param args: Arguments to be passed to "mount" command.
650 @param record: If True, output result of mount operation to autotest 650 @param record: If True, output result of mount operation to autotest
651 output. 651 output.
(...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after
977 os.remove(self.img) 977 os.remove(self.img)
978 except: 978 except:
979 e_msg = 'Error removing image file %s' % self.img 979 e_msg = 'Error removing image file %s' % self.img
980 raise error.AutotestError(e_msg) 980 raise error.AutotestError(e_msg)
981 981
982 # import a site partition module to allow it to override functions 982 # import a site partition module to allow it to override functions
983 try: 983 try:
984 from autotest_lib.client.bin.site_partition import * 984 from autotest_lib.client.bin.site_partition import *
985 except ImportError: 985 except ImportError:
986 pass 986 pass
OLDNEW
« no previous file with comments | « client/bin/kernel_unittest.py ('k') | client/common_lib/log.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698