TESTS update all read16 tests to fail/skip on illegal opcode depending on whether the device claims support for it or not (mandatory in sbc-3, optional prior)

This commit is contained in:
Ronnie Sahlberg
2013-04-22 17:31:50 -07:00
parent 77ff1b1808
commit 79f54c5e06
9 changed files with 102 additions and 20 deletions

View File

@@ -34,6 +34,11 @@ test_read16_0blocks(void)
logging(LOG_VERBOSE, "Test READ16 0-blocks at LBA==0");
ret = read16(iscsic, tgt_lun, 0, 0, block_size,
0, 0, 0, 0, 0, NULL);
if (ret == -2) {
logging(LOG_NORMAL, "[SKIPPED] READ16 is not implemented on this target and it does not claim SBC-3 support.");
CU_PASS("READ16 is not implemented and no SBC-3 support claimed.");
return;
}
CU_ASSERT_EQUAL(ret, 0);
logging(LOG_VERBOSE, "Test READ16 0-blocks one block past end-of-LUN");