OLD | NEW |
---|---|
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 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 checkout.py.""" | 6 """Unit tests for checkout.py.""" |
7 | 7 |
8 import logging | 8 import logging |
9 import os | 9 import os |
10 import shutil | 10 import shutil |
(...skipping 436 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
447 remote_branch='master', | 447 remote_branch='master', |
448 git_url=os.path.join(self.FAKE_REPOS.git_root, | 448 git_url=os.path.join(self.FAKE_REPOS.git_root, |
449 self.FAKE_REPOS.TEST_GIT_REPO), | 449 self.FAKE_REPOS.TEST_GIT_REPO), |
450 commit_user=self.usr, | 450 commit_user=self.usr, |
451 post_processors=post_processors) | 451 post_processors=post_processors) |
452 | 452 |
453 def testAll(self): | 453 def testAll(self): |
454 root = os.path.join(self.root_dir, self.name) | 454 root = os.path.join(self.root_dir, self.name) |
455 self._check_base(self._get_co(None), root, None) | 455 self._check_base(self._get_co(None), root, None) |
456 | 456 |
457 @unittest.skip("flaky") | |
Adrian Kuegel
2015/04/21 15:04:22
nit: same here.
| |
457 def testException(self): | 458 def testException(self): |
458 self._check_exception( | 459 self._check_exception( |
459 self._get_co(None), | 460 self._get_co(None), |
460 'While running git apply --index -3 -p1;\n fatal: corrupt patch at ' | 461 'While running git apply --index -3 -p1;\n fatal: corrupt patch at ' |
461 'line 12\n') | 462 'line 12\n') |
462 | 463 |
463 def testProcess(self): | 464 def testProcess(self): |
464 self._test_process(self._get_co) | 465 self._test_process(self._get_co) |
465 | 466 |
466 def _testPrepare(self): | 467 def _testPrepare(self): |
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
733 if '-v' in sys.argv: | 734 if '-v' in sys.argv: |
734 DEBUGGING = True | 735 DEBUGGING = True |
735 logging.basicConfig( | 736 logging.basicConfig( |
736 level=logging.DEBUG, | 737 level=logging.DEBUG, |
737 format='%(levelname)5s %(filename)15s(%(lineno)3d): %(message)s') | 738 format='%(levelname)5s %(filename)15s(%(lineno)3d): %(message)s') |
738 else: | 739 else: |
739 logging.basicConfig( | 740 logging.basicConfig( |
740 level=logging.ERROR, | 741 level=logging.ERROR, |
741 format='%(levelname)5s %(filename)15s(%(lineno)3d): %(message)s') | 742 format='%(levelname)5s %(filename)15s(%(lineno)3d): %(message)s') |
742 unittest.main() | 743 unittest.main() |
OLD | NEW |