This ensures a specific file is actually an image.
function testFileValidateIsImage() {
$this
->assertTrue(file_exists($this->image->uri), t('The image being tested exists.'), 'File');
$errors = file_validate_is_image($this->image);
$this
->assertEqual(count($errors), 0, t('No error reported for our image file.'), 'File');
$this
->assertTrue(file_exists($this->non_image->uri), t('The non-image being tested exists.'), 'File');
$errors = file_validate_is_image($this->non_image);
$this
->assertEqual(count($errors), 1, t('An error reported for our non-image file.'), 'File');
}