]> BookStack Code Mirror - bookstack/blobdiff - tests/Helpers/FileProvider.php
Tests: Updated comment test to account for new editor usage
[bookstack] / tests / Helpers / FileProvider.php
index 99ee11efbad8b355e136a794c9b2215b8b594e18..a455e0fb4ea503641a91d5c018d147db80c628d5 100644 (file)
@@ -60,6 +60,14 @@ class FileProvider
         return file_get_contents($this->testFilePath('test-image.png'));
     }
 
+    /**
+     * Get raw data for a Jpeg image test file.
+     */
+    public function jpegImageData(): string
+    {
+        return file_get_contents($this->testFilePath('test-image.jpg'));
+    }
+
     /**
      * Get the expected relative path for an uploaded image of the given type and filename.
      */
@@ -159,4 +167,12 @@ class FileProvider
             $fileService->deleteFile($file);
         }
     }
+
+    /**
+     * Reset the application favicon image in the public path.
+     */
+    public function resetAppFavicon(): void
+    {
+        file_put_contents(public_path('favicon.ico'), file_get_contents(public_path('icon.ico')));
+    }
 }