Skip to content

Commit c433ee9

Browse files
committed
tests/input_validation_tests.py::invalid_patch_targets(): Improve the test
by adding more assertions for different combinations of valid and bad paths of patch files and working copies. * subversion/tests/cmdline/input_validation_tests.py (invalid_patch_targets): Ditto (and expand for loop). git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1925478 13f79535-47bb-0310-9956-ffa450edef68
1 parent e1d7a36 commit c433ee9

1 file changed

Lines changed: 12 additions & 3 deletions

File tree

subversion/tests/cmdline/input_validation_tests.py

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -222,9 +222,18 @@ def invalid_status_targets(sbox):
222222
def invalid_patch_targets(sbox):
223223
"non-working copy paths for 'patch'"
224224
sbox.build(read_only=True)
225-
for (target1, target2) in [("foo", "^/"), ("^/", "^/"), ("^/", "foo")]:
226-
run_and_verify_svn_in_wc(sbox, "svn:.*is not a local path", 'patch',
227-
target1, target2)
225+
226+
run_and_verify_svn_in_wc(sbox, "svn:.*is not a local path", 'patch',
227+
"iota", "^/")
228+
229+
run_and_verify_svn_in_wc(sbox, "svn:.*is not a local path", 'patch',
230+
"^/", "^/")
231+
232+
run_and_verify_svn_in_wc(sbox, "svn:.*does not exist", 'patch',
233+
"non-existent.patch", "")
234+
235+
run_and_verify_svn_in_wc(sbox, "svn:.*does not exist", 'patch',
236+
"iota", "non-existent-wc")
228237

229238
def invalid_switch_targets(sbox):
230239
"non-working copy paths for 'switch'"

0 commit comments

Comments
 (0)