]> BookStack Code Mirror - bookstack/blobdiff - tests/ImageTest.php
Update/fix german translation
[bookstack] / tests / ImageTest.php
index 234988ba402c18da448ac0d5714c86f4b88edc50..3bb41138bae7d50dd8d9821fed27bf0ad54ebad0 100644 (file)
@@ -1,6 +1,6 @@
-<?php
+<?php namespace Tests;
 
-class ImageTest extends TestCase
+class ImageTest extends BrowserKitTest
 {
 
     /**
@@ -57,7 +57,7 @@ class ImageTest extends TestCase
         $relPath = $this->uploadImage($imageName, $page->id);
         $this->assertResponseOk();
 
-        $this->assertTrue(file_exists(public_path($relPath)), 'Uploaded image exists');
+        $this->assertTrue(file_exists(public_path($relPath)), 'Uploaded image not found at path: '. public_path($relPath));
 
         $this->deleteImage($relPath);
 
@@ -70,7 +70,6 @@ class ImageTest extends TestCase
             'updated_by' => $admin->id,
             'name' => $imageName
         ]);
-        
 
     }
 
@@ -91,7 +90,7 @@ class ImageTest extends TestCase
             'type' => 'gallery'
         ]);
 
-        $this->assertFalse(file_exists(public_path($relPath)), 'Uploaded image has been deleted');
+        $this->assertFalse(file_exists(public_path($relPath)), 'Uploaded image has not been deleted as expected');
     }
 
 }
\ No newline at end of file