| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium 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 base64 | 5 import base64 |
| 6 from datetime import datetime | 6 from datetime import datetime |
| 7 import json | 7 import json |
| 8 import re | 8 import re |
| 9 | 9 |
| 10 from testing_utils import testing | 10 from testing_utils import testing |
| 11 | 11 |
| 12 from gae_libs.testcase import TestCase | 12 from gae_libs.testcase import TestCase |
| 13 from lib.gitiles import gitiles_repository | 13 from libs.gitiles import gitiles_repository |
| 14 from lib.gitiles.change_log import ChangeLog | 14 from libs.gitiles.change_log import ChangeLog |
| 15 from libs.http import retry_http_client | 15 from libs.http import retry_http_client |
| 16 | 16 |
| 17 | 17 |
| 18 COMMIT_MESSAGE = ('Add popover for snapshot canvas log.\n\n' | 18 COMMIT_MESSAGE = ('Add popover for snapshot canvas log.\n\n' |
| 19 'Review URL: https://codereview.chromium.org/320423004\n\n' | 19 'Review URL: https://codereview.chromium.org/320423004\n\n' |
| 20 'Review URL: https://codereview.chromium.org/328113005\n\n' | 20 'Review URL: https://codereview.chromium.org/328113005\n\n' |
| 21 'Cr-Commit-Position: refs/heads/master@{#175976}') | 21 'Cr-Commit-Position: refs/heads/master@{#175976}') |
| 22 | 22 |
| 23 COMMIT_LOG = """)]}' | 23 COMMIT_LOG = """)]}' |
| 24 { | 24 { |
| (...skipping 416 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 441 '_SendRequestForJsonResponse', _MockSendRequestForJsonResponse) | 441 '_SendRequestForJsonResponse', _MockSendRequestForJsonResponse) |
| 442 | 442 |
| 443 changelogs = self.git_repo.GetChangeLogs('0', '2') | 443 changelogs = self.git_repo.GetChangeLogs('0', '2') |
| 444 | 444 |
| 445 self.assertEqual(len(changelogs), 2) | 445 self.assertEqual(len(changelogs), 2) |
| 446 | 446 |
| 447 def testGetWrappedGitRepositoryClass(self): | 447 def testGetWrappedGitRepositoryClass(self): |
| 448 repo = gitiles_repository.GitilesRepository( | 448 repo = gitiles_repository.GitilesRepository( |
| 449 self.http_client_for_git, 'http://repo_url') | 449 self.http_client_for_git, 'http://repo_url') |
| 450 self.assertEqual(repo.repo_url, 'http://repo_url') | 450 self.assertEqual(repo.repo_url, 'http://repo_url') |
| OLD | NEW |