From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: From: Dmitry Fomichev Subject: [PATCH v3 23/38] t/zbd: check for error in test #2 Date: Thu, 7 Jan 2021 06:57:24 +0900 Message-Id: <20210106215739.264524-24-dmitry.fomichev@wdc.com> In-Reply-To: <20210106215739.264524-1-dmitry.fomichev@wdc.com> References: <20210106215739.264524-1-dmitry.fomichev@wdc.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit To: Jens Axboe , fio@vger.kernel.org, Aravind Ramesh , Bart Van Assche , Naohiro Aota , Niklas Cassel Cc: Damien Le Moal , Shinichiro Kawasaki , Dmitry Fomichev List-ID: With the preceding commit in place, fio gives an error if user attempts to run write I/O size that is larger than the zone size. Grep for that message instead of checking that no write has happened. Signed-off-by: Dmitry Fomichev --- t/zbd/test-zbd-support | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/t/zbd/test-zbd-support b/t/zbd/test-zbd-support index acde3b3a..652dddfc 100755 --- a/t/zbd/test-zbd-support +++ b/t/zbd/test-zbd-support @@ -221,8 +221,8 @@ test2() { if [ -z "$is_zbd" ]; then opts+=("--zonesize=${zone_size}") fi - run_fio "${opts[@]}" >> "${logfile}.${test_number}" 2>&1 || return $? - ! grep -q 'WRITE:' "${logfile}.${test_number}" + run_fio "${opts[@]}" >> "${logfile}.${test_number}" 2>&1 && return 1 + grep -q 'buflen exceeds zone size' "${logfile}.${test_number}" } # Run fio against an empty zone. This causes fio to report "No I/O performed". -- 2.28.0