Thread (11 messages) 11 messages, 4 authors, 2024-03-10

Re: [GSOC][RFC PATCH 0/1] microproject: use test_path_is_* functions in test scripts

From: Eric Sunshine <hidden>
Date: 2024-02-19 19:36:56

On Mon, Feb 19, 2024 at 12:22 PM Vincenzo Mezzela
[off-list ref] wrote:
Would you like to see something like
'''
test_path_is_missing file1 &&
test_path_is_file file2 &&
test_path_is_missing file3 &&
test_path_is_file file5
'''
changed into
'''
test_path_is_file file2 &&
test_path_is_file file5 &&
test_path_is_missing file3 &&
test_path_is_missing file1
'''
where all the test_path_is_file are grouped before and followed by all
the test_path_is_missing (or the other way around) to enhance
readability of the code?
Generally speaking, no, reviewers would not want to see such a change
because "enhanced readability" is often quite subjective. More
importantly, though, reviewers would especially not want this done in
the same patch which changes `test -blah` to `test_path_foo` because
it make it harder for the reviewer to associate and verify each `test
-blah` to `test_path_foo` replacement in the final result with the
source statement in the original file. It's much easier for a reviewer
to validate old against new when there is an obvious one-to-one
correspondence.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help