Tests: Add a helper for the all_zero checker

Signed-off-by: Ronnie Sahlberg <ronniesahlberg@gmail.com>
This commit is contained in:
Ronnie Sahlberg
2016-02-23 19:26:15 -08:00
parent b4320bd76c
commit 8a44851128
8 changed files with 25 additions and 30 deletions

View File

@@ -58,7 +58,7 @@ test_writesame16_unmap(void)
READ16(sd, NULL, 0, i * block_size, block_size,
0, 0, 0, 0, 0, scratch,
EXPECT_STATUS_GOOD);
CU_ASSERT(all_zeroes(scratch, i * block_size));
ALL_ZERO(scratch, i * block_size);
} else {
logging(LOG_VERBOSE, "LBPRZ is clear. Skip the read "
"and verify zero test");
@@ -89,7 +89,7 @@ test_writesame16_unmap(void)
i * block_size, block_size,
0, 0, 0, 0, 0, scratch,
EXPECT_STATUS_GOOD);
CU_ASSERT(all_zeroes(scratch, i * block_size));
ALL_ZERO(scratch, i * block_size);
} else {
logging(LOG_VERBOSE, "LBPRZ is clear. Skip the read "
"and verify zero test");
@@ -147,7 +147,7 @@ test_writesame16_unmap(void)
READ16(sd, NULL, 0, i * block_size, block_size,
0, 0, 0, 0, 0, scratch,
EXPECT_STATUS_GOOD);
CU_ASSERT(all_zeroes(scratch, i * block_size));
ALL_ZERO(scratch, i * block_size);
} else {
logging(LOG_VERBOSE, "LBPRZ is clear. Skip the read "
"and verify zero test");
@@ -191,7 +191,7 @@ test_writesame16_unmap(void)
READ16(sd, NULL, 0, i * block_size, block_size,
0, 0, 0, 0, 0, scratch,
EXPECT_STATUS_GOOD);
CU_ASSERT(all_zeroes(scratch, i * block_size));
ALL_ZERO(scratch, i * block_size);
} else {
logging(LOG_VERBOSE, "LBPRZ is clear. Skip the read "
"and verify zero test");