]> www.infradead.org Git - users/hch/blktests.git/commit
new: fix test case addition to new test group
authorShin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Tue, 19 Jul 2022 03:10:36 +0000 (12:10 +0900)
committerShin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Sun, 24 Jul 2022 23:47:27 +0000 (08:47 +0900)
commit1e6f4b28d8e6f0cf49db45657183cdadcfbc1cb5
tree56d6e2de12fb8d02d95266d3842729c6ca90e3c5
parent349eb683fd06f6bee70cd91172e6aaa7986810dd
new: fix test case addition to new test group

The "new" script adds script files for a new test case to the specified
test group. However, this file addition fails when the user specifies
non-existing new test group name as the target test group. The failure
happens because the "new" script assumes the target test group directory
has at least one test case, but this is not true when a new group is
created. Fix this by checking the existence of the test cases in the
target test group.

Fixes: b1e29e775872 ("Create test name from most recently used test number")
Signed-off-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
new