TESTS: Add tests for WRITEVERIFY10/12/16

This commit is contained in:
Ronnie Sahlberg
2013-02-18 20:16:41 -08:00
parent 02010f9157
commit fc1b2697d4
22 changed files with 1594 additions and 23 deletions

View File

@@ -108,10 +108,35 @@ test_readonly_sbc(void)
}
CU_ASSERT_NOT_EQUAL(ret, -1);
logging(LOG_VERBOSE, "Test WRITEVERIFY10 fails with WRITE_PROTECTED");
ret = writeverify10_writeprotected(iscsic, tgt_lun, 0,
block_size, block_size,
0, 0, 0, 0, buf);
if (ret == -2) {
logging(LOG_VERBOSE, "WRITEVERIFY10 not supported on target. Skipped.");
}
CU_ASSERT_NOT_EQUAL(ret, -1);
logging(LOG_VERBOSE, "Test WRITEVERIFY12 fails with WRITE_PROTECTED");
ret = writeverify12_writeprotected(iscsic, tgt_lun, 0,
block_size, block_size,
0, 0, 0, 0, buf);
if (ret == -2) {
logging(LOG_VERBOSE, "WRITEVERIFY12 not supported on target. Skipped.");
}
CU_ASSERT_NOT_EQUAL(ret, -1);
logging(LOG_VERBOSE, "Test WRITEVERIFY16 fails with WRITE_PROTECTED");
ret = writeverify16_writeprotected(iscsic, tgt_lun, 0,
block_size, block_size,
0, 0, 0, 0, buf);
if (ret == -2) {
logging(LOG_VERBOSE, "WRITEVERIFY16 not supported on target. Skipped.");
}
CU_ASSERT_NOT_EQUAL(ret, -1);
/* NOT implemented yet */
logging(LOG_VERBOSE, "Test for WRITEVERIFY10 not implemented yet.");
logging(LOG_VERBOSE, "Test for WRITEVERIFY12 not implemented yet.");
logging(LOG_VERBOSE, "Test for WRITEVERIFY16 not implemented yet.");
logging(LOG_VERBOSE, "Test for COMPAREANDWRITE not implemented yet.");
logging(LOG_VERBOSE, "Test for ORWRITE not implemented yet.");
}