@Test
public void testValidateStorageUnitS3FilesRegisteredFileNoExists() throws IOException
{

    StorageUnit storageUnit = createStorageUnit(TEST_S3_KEY_PREFIX, LOCAL_FILES, FILE_SIZE_1_KB);
    List<String> actualS3Files = new ArrayList<>();
    // Try to validate S3 files when actual S3 files do not exist.
    try
    {
        storageFileHelper.validateStorageUnitS3Files(storageUnit, actualS3Files, TEST_S3_KEY_PREFIX);
        fail("Should throw a RuntimeException when actual S3 files do not exist.");
    }
    catch (RuntimeException e)
    {
        String expectedErrMsg = String
            .format("Registered file \"%s\" does not exist in \"%s\" storage.", storageUnit.getStorageFiles().get(0).getFilePath(),
                storageUnit.getStorage().getName());
        assertEquals(expectedErrMsg, e.getMessage());
    }
}