diff --git a/tests/Plugins/MediaEmbed/ParserTest.php b/tests/Plugins/MediaEmbed/ParserTest.php
index <HASH>..<HASH> 100644
--- a/tests/Plugins/MediaEmbed/ParserTest.php
+++ b/tests/Plugins/MediaEmbed/ParserTest.php
@@ -23,6 +23,11 @@ class ParserTest extends Test
 	{
 		$cacheDir = __DIR__ . '/../../.cache';
 
+		if (!file_exists($cacheDir))
+		{
+			$cacheDir = sys_get_temp_dir();
+		}
+
 		$prefix = $suffix = '';
 		if (extension_loaded('zlib'))
 		{
MediaEmbed/ParserTest: use the system's temp dir if there's no .cache dir in the tests dir