TESTS: update the READ tests to the new API

Signed-off-by: Ronnie Sahlberg <sahlberg@localhost>
This commit is contained in:
Ronnie Sahlberg
2014-09-17 13:03:23 -07:00
committed by Ronnie Sahlberg
parent 4b2e9bd417
commit 28b0a0ab11
52 changed files with 324 additions and 803 deletions

View File

@@ -37,8 +37,8 @@ test_read12_flags(void)
logging(LOG_VERBOSE, "Test READ12 with DPO==1");
ret = read12(iscsic, tgt_lun, 0,
block_size, block_size,
0, 1, 0, 0, 0, NULL);
block_size, block_size, 0, 1, 0, 0, 0, NULL,
EXPECT_STATUS_GOOD);
if (ret == -2) {
logging(LOG_NORMAL, "[SKIPPED] READ12 is not implemented.");
CU_PASS("READ12 is not implemented.");
@@ -49,28 +49,28 @@ test_read12_flags(void)
logging(LOG_VERBOSE, "Test READ12 with FUA==1 FUA_NV==0");
ret = read12(iscsic, tgt_lun, 0,
block_size, block_size,
0, 0, 1, 0, 0, NULL);
block_size, block_size, 0, 0, 1, 0, 0, NULL,
EXPECT_STATUS_GOOD);
CU_ASSERT_EQUAL(ret, 0);
logging(LOG_VERBOSE, "Test READ12 with FUA==1 FUA_NV==1");
ret = read12(iscsic, tgt_lun, 0,
block_size, block_size,
0, 0, 1, 1, 0, NULL);
block_size, block_size, 0, 0, 1, 1, 0, NULL,
EXPECT_STATUS_GOOD);
CU_ASSERT_EQUAL(ret, 0);
logging(LOG_VERBOSE, "Test READ12 with FUA==0 FUA_NV==1");
ret = read12(iscsic, tgt_lun, 0,
block_size, block_size,
0, 0, 0, 1, 0, NULL);
block_size, block_size, 0, 0, 0, 1, 0, NULL,
EXPECT_STATUS_GOOD);
CU_ASSERT_EQUAL(ret, 0);
logging(LOG_VERBOSE, "Test READ12 with DPO==1 FUA==1 FUA_NV==1");
ret = read12(iscsic, tgt_lun, 0,
block_size, block_size,
0, 1, 1, 1, 0, NULL);
block_size, block_size, 0, 1, 1, 1, 0, NULL,
EXPECT_STATUS_GOOD);
CU_ASSERT_EQUAL(ret, 0);
}