| 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 scm.py.""" | 6 """Unit tests for scm.py.""" |
| 7 | 7 |
| 8 import logging | 8 import logging |
| 9 import os | 9 import os |
| 10 import sys | 10 import sys |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 self.compareMembers(scm, members) | 70 self.compareMembers(scm, members) |
| 71 | 71 |
| 72 | 72 |
| 73 class GitWrapperTestCase(BaseSCMTestCase): | 73 class GitWrapperTestCase(BaseSCMTestCase): |
| 74 def testMembersChanged(self): | 74 def testMembersChanged(self): |
| 75 members = [ | 75 members = [ |
| 76 'ApplyEnvVars', | 76 'ApplyEnvVars', |
| 77 'AssertVersion', | 77 'AssertVersion', |
| 78 'Capture', | 78 'Capture', |
| 79 'CaptureStatus', | 79 'CaptureStatus', |
| 80 'CleanupDir', |
| 80 'current_version', | 81 'current_version', |
| 81 'FetchUpstreamTuple', | 82 'FetchUpstreamTuple', |
| 82 'GenerateDiff', | 83 'GenerateDiff', |
| 83 'GetBlessedSha1ForSvnRev', | 84 'GetBlessedSha1ForSvnRev', |
| 84 'GetBranch', | 85 'GetBranch', |
| 85 'GetBranchRef', | 86 'GetBranchRef', |
| 86 'GetCheckoutRoot', | 87 'GetCheckoutRoot', |
| 87 'GetDifferentFiles', | 88 'GetDifferentFiles', |
| 88 'GetEmail', | 89 'GetEmail', |
| 89 'GetGitDir', | 90 'GetGitDir', |
| 90 'GetGitSvnHeadRev', | 91 'GetGitSvnHeadRev', |
| 91 'GetPatchName', | 92 'GetPatchName', |
| 92 'GetSha1ForSvnRev', | 93 'GetSha1ForSvnRev', |
| 93 'GetSVNBranch', | 94 'GetSVNBranch', |
| 94 'GetUpstreamBranch', | 95 'GetUpstreamBranch', |
| 96 'IsDirectoryVersioned', |
| 95 'IsGitSvn', | 97 'IsGitSvn', |
| 96 'IsInsideWorkTree', | 98 'IsInsideWorkTree', |
| 97 'IsValidRevision', | 99 'IsValidRevision', |
| 98 'IsWorkTreeDirty', | 100 'IsWorkTreeDirty', |
| 99 'MatchSvnGlob', | 101 'MatchSvnGlob', |
| 100 'ParseGitSvnSha1', | 102 'ParseGitSvnSha1', |
| 101 'RefToRemoteRef', | 103 'RefToRemoteRef', |
| 102 'ShortBranchName', | 104 'ShortBranchName', |
| 103 ] | 105 ] |
| 104 # If this test fails, you should add the relevant test. | 106 # If this test fails, you should add the relevant test. |
| (...skipping 368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 473 self.assertTrue(scm.SVN.IsValidRevision(url_at_rev % 2)) | 475 self.assertTrue(scm.SVN.IsValidRevision(url_at_rev % 2)) |
| 474 self.assertTrue(scm.SVN.IsValidRevision(url_at_rev % 'HEAD')) | 476 self.assertTrue(scm.SVN.IsValidRevision(url_at_rev % 'HEAD')) |
| 475 | 477 |
| 476 | 478 |
| 477 if __name__ == '__main__': | 479 if __name__ == '__main__': |
| 478 if '-v' in sys.argv: | 480 if '-v' in sys.argv: |
| 479 logging.basicConfig(level=logging.DEBUG) | 481 logging.basicConfig(level=logging.DEBUG) |
| 480 unittest.main() | 482 unittest.main() |
| 481 | 483 |
| 482 # vim: ts=2:sw=2:tw=80:et: | 484 # vim: ts=2:sw=2:tw=80:et: |
| OLD | NEW |