Index: tests/image.test
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/image/tests/image.test,v
retrieving revision 1.3
diff -u -p -r1.3 image.test
--- tests/image.test	1 Feb 2009 03:10:34 -0000	1.3
+++ tests/image.test	1 Feb 2009 03:17:23 -0000
@@ -117,4 +117,20 @@ class ImageTestCase extends DrupalWebTes
       (filesize($node_post->images['thumbnail']) == filesize($node_api->images['thumbnail']));
     $this->assertTrue($equality, t('Images nodes are equal.'));
   }
+
+  /**
+   * Verify that images cannot be created without a file.
+   */
+  function testMissingImage() {
+    $edit = array(
+      'title' => $this->randomName(),
+      'body' => $this->randomName(),
+    );
+    $this->drupalPost('node/add/image', $edit, t('Save'));
+    
+    $this->assertRaw(t('You need to upload an image.'), t('Refused node creation without image.'));
+    
+    $node = node_load(array('title' => $edit['title']));
+    $this->assertFalse($node, t('Image node not found in database.'));
+  }
 }
