OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2011 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2011 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 """Unit tests for gclient_scm.py.""" | 6 """Unit tests for gclient_scm.py.""" |
7 | 7 |
8 # pylint: disable=E1101,E1103,W0403 | 8 # pylint: disable=E1101,E1103,W0403 |
9 | 9 |
10 # Import before super_mox to keep valid references. | 10 # Import before super_mox to keep valid references. |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 class SVNWrapperTestCase(BaseTestCase): | 66 class SVNWrapperTestCase(BaseTestCase): |
67 class OptionsObject(object): | 67 class OptionsObject(object): |
68 def __init__(self, verbose=False, revision=None): | 68 def __init__(self, verbose=False, revision=None): |
69 self.verbose = verbose | 69 self.verbose = verbose |
70 self.revision = revision | 70 self.revision = revision |
71 self.manually_grab_svn_rev = True | 71 self.manually_grab_svn_rev = True |
72 self.deps_os = None | 72 self.deps_os = None |
73 self.force = False | 73 self.force = False |
74 self.reset = False | 74 self.reset = False |
75 self.nohooks = False | 75 self.nohooks = False |
76 # TODO(maruel): Test --jobs > 1. | |
77 self.jobs = 1 | |
78 | 76 |
79 def Options(self, *args, **kwargs): | 77 def Options(self, *args, **kwargs): |
80 return self.OptionsObject(*args, **kwargs) | 78 return self.OptionsObject(*args, **kwargs) |
81 | 79 |
82 def setUp(self): | 80 def setUp(self): |
83 BaseTestCase.setUp(self) | 81 BaseTestCase.setUp(self) |
84 self.url = self.SvnUrl() | 82 self.url = self.SvnUrl() |
85 | 83 |
86 def testDir(self): | 84 def testDir(self): |
87 members = [ | 85 members = [ |
(...skipping 803 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
891 | 889 |
892 if __name__ == '__main__': | 890 if __name__ == '__main__': |
893 if '-v' in sys.argv: | 891 if '-v' in sys.argv: |
894 logging.basicConfig( | 892 logging.basicConfig( |
895 level=logging.DEBUG, | 893 level=logging.DEBUG, |
896 format='%(asctime).19s %(levelname)s %(filename)s:' | 894 format='%(asctime).19s %(levelname)s %(filename)s:' |
897 '%(lineno)s %(message)s') | 895 '%(lineno)s %(message)s') |
898 unittest.main() | 896 unittest.main() |
899 | 897 |
900 # vim: ts=2:sw=2:tw=80:et: | 898 # vim: ts=2:sw=2:tw=80:et: |
OLD | NEW |