@Test
public void testGetPartitionValue()
{

    // Create and persist test database entities.
    BusinessObjectDataEntity businessObjectDataEntity = businessObjectDataDaoTestHelper
        .createBusinessObjectDataEntity(NAMESPACE, BDEF_NAME, FORMAT_USAGE_CODE, FORMAT_FILE_TYPE_CODE, FORMAT_VERSION, PARTITION_VALUE,
            SUBPARTITION_VALUES, DATA_VERSION, true, BDATA_STATUS);
    // Retrieve primary and sub-partition values along with trying the "out of bounds" cases.
    assertEquals(null, businessObjectDataHelper.getPartitionValue(businessObjectDataEntity, 0));
    assertEquals(PARTITION_VALUE, businessObjectDataHelper.getPartitionValue(businessObjectDataEntity, 1));
    for (int partitionColumnPosition = 2; partitionColumnPosition <= BusinessObjectDataEntity.MAX_SUBPARTITIONS + 1; partitionColumnPosition++)
    {
        assertEquals(SUBPARTITION_VALUES.get(partitionColumnPosition - 2),
            businessObjectDataHelper.getPartitionValue(businessObjectDataEntity, partitionColumnPosition));
    }
    assertEquals(null, businessObjectDataHelper.getPartitionValue(businessObjectDataEntity, BusinessObjectDataEntity.MAX_SUBPARTITIONS + 2));
}