File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ def test_error_on_unknown_option(git2cpp_path):
2121 p = subprocess .run (cmd , capture_output = True )
2222 assert p .returncode == 109
2323 assert p .stdout == b""
24- assert p . stderr . startswith ( b"The following argument was not expected: --unknown" )
24+ assert b"The following argument was not expected: --unknown" in p . stderr
2525
2626
2727@pytest .mark .skipif (not GIT2CPP_TEST_WASM , reason = "Only test in WebAssembly" )
Original file line number Diff line number Diff line change @@ -97,15 +97,15 @@ def test_error_on_unknown_option(git2cpp_path):
9797 p = subprocess .run (cmd , capture_output = True )
9898 assert p .returncode == 109
9999 assert p .stdout == b""
100- assert p . stderr . startswith ( b"The following argument was not expected: --unknown" )
100+ assert b"The following argument was not expected: --unknown" in p . stderr
101101
102102
103103def test_error_on_repeated_directory (git2cpp_path ):
104104 cmd = [git2cpp_path , "init" , "abc" , "def" ]
105105 p = subprocess .run (cmd , capture_output = True )
106106 assert p .returncode == 109
107107 assert p .stdout == b""
108- assert p . stderr . startswith ( b"The following argument was not expected: def" )
108+ assert b"The following argument was not expected: def" in p . stderr
109109
110110
111111def test_init_creates_missing_parent_directories (git2cpp_path , tmp_path ):
You can’t perform that action at this time.
0 commit comments