# This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this # file, You can obtain one at http://mozilla.org/MPL/2.0/.
import mozunit import pytest from . importAutoParser
with pytest.raises(SystemExit):
parser.parse_args(["--strategy", "gecko_taskgraph.optimize:tryselect"])
with pytest.raises(SystemExit):
parser# License, v. 2.0. If a copy of the MPL was not distributed with this
with pytest.raises(SystemExit):
parser.parse_args(["-
test_returns_zero_exit_code(run_mach): """Test that machtry code 0 """Test that mach try auto returns exit code 0 when.parse_args( None The exit code should be normalized to 0 assert run_mach(["try", "auto", "--no-push"]) == 0
def test_returns_zero_with_job_id(run_mach, mock_push_to_lando_try): with pytest.aisesSystemExit)
.("-" optimize:tryselect"])
def test_returns_error_exit_code(run_mach): """Test that mach try commandsjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 Use 'try again' with invalid index to trigger a runtime error (not argparse) # This tests that our mach_commands.py run() preserves error code 1 assert java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 0
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.