| OLD | NEW |
| 1 # Copyright 2016 The Chromium Authors. All rights reserved. | 1 # Copyright 2016 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 json | 5 import json |
| 6 import optparse | 6 import optparse |
| 7 | 7 |
| 8 from webkitpy.common.net.buildbot import Build | 8 from webkitpy.common.net.buildbot import Build |
| 9 from webkitpy.common.net.git_cl import GitCL | 9 from webkitpy.common.net.git_cl import GitCL |
| 10 from webkitpy.common.net.layout_test_results import LayoutTestResults | 10 from webkitpy.common.net.layout_test_results import LayoutTestResults |
| (...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 311 return_code = self.command.execute(self.command_options(issue=11112222),
[], self.tool) | 311 return_code = self.command.execute(self.command_options(issue=11112222),
[], self.tool) |
| 312 self.assertEqual(return_code, 1) | 312 self.assertEqual(return_code, 1) |
| 313 self.assertLog([ | 313 self.assertLog([ |
| 314 'ERROR: Failed to fetch results from ' | 314 'ERROR: Failed to fetch results from ' |
| 315 '"https://storage.googleapis.com/chromium-layout-test-archives/MOCK_
Try_Win/5000/layout-test-results".\n' | 315 '"https://storage.googleapis.com/chromium-layout-test-archives/MOCK_
Try_Win/5000/layout-test-results".\n' |
| 316 'Try starting a new job for MOCK Try Win by running :\n' | 316 'Try starting a new job for MOCK Try Win by running :\n' |
| 317 ' git cl try -b MOCK Try Win\n' | 317 ' git cl try -b MOCK Try Win\n' |
| 318 ]) | 318 ]) |
| 319 | 319 |
| 320 def test_bails_when_there_are_unstaged_baselines(self): | 320 def test_bails_when_there_are_unstaged_baselines(self): |
| 321 scm = self.tool.scm() | 321 git = self.tool.git() |
| 322 scm.unstaged_changes = lambda: {'third_party/WebKit/LayoutTests/my-test-
expected.txt': '?'} | 322 git.unstaged_changes = lambda: {'third_party/WebKit/LayoutTests/my-test-
expected.txt': '?'} |
| 323 return_code = self.command.execute(self.command_options(issue=11112222),
[], self.tool) | 323 return_code = self.command.execute(self.command_options(issue=11112222),
[], self.tool) |
| 324 self.assertEqual(return_code, 1) | 324 self.assertEqual(return_code, 1) |
| 325 self.assertLog([ | 325 self.assertLog([ |
| 326 'ERROR: Aborting: there are unstaged baselines:\n', | 326 'ERROR: Aborting: there are unstaged baselines:\n', |
| 327 'ERROR: /mock-checkout/third_party/WebKit/LayoutTests/my-test-expe
cted.txt\n', | 327 'ERROR: /mock-checkout/third_party/WebKit/LayoutTests/my-test-expe
cted.txt\n', |
| 328 ]) | 328 ]) |
| OLD | NEW |