TESTS: Add tests that get_lba_status for a single range works

Add a test for unmapping a single range of blocks and that
get_lba_status returns correct data.

Test unmapping a single block at offsets 0-255

Test unmapping 1-255 blocks at offset 0 and verify that
get_lba_status at LBA 0 returns a descriptor of 1-255 blocks.
get_lba_status at the last block of the unmapped range returns
a descriptor for a single block.

Signed-off-by: Ronnie Sahlberg <ronniesahlberg@gmail.com>
This commit is contained in:
Ronnie Sahlberg
2014-07-14 19:46:12 -07:00
parent f0ebbdc203
commit a41ec1fe60
4 changed files with 251 additions and 0 deletions
+1
View File
@@ -71,6 +71,7 @@ static CU_TestInfo tests_compareandwrite[] = {
static CU_TestInfo tests_get_lba_status[] = {
{ (char *)"Simple", test_get_lba_status_simple },
{ (char *)"BeyondEol", test_get_lba_status_beyond_eol },
{ (char *)"UnmapSingle", test_get_lba_status_unmap_single },
CU_TEST_INFO_NULL
};