diff --git a/Tests/ResourceMirrorTest.php b/Tests/ResourceMirrorTest.php
index <HASH>..<HASH> 100644
--- a/Tests/ResourceMirrorTest.php
+++ b/Tests/ResourceMirrorTest.php
@@ -37,4 +37,15 @@ class ResourceMirrorTest extends \PHPUnit_Framework_TestCase
         $mirror = new ResourceMirror(new EventDispatcher(), 'http://example.com/', $tempDir = sys_get_temp_dir());
         $this->assertEquals($tempDir, $mirror->getDirectory());
     }
+
+    /**
+     * A resource mirror is not created if directory is not writable.
+     *
+     * @depends testCreate
+     * @expectedException \InvalidArgumentException
+     */
+    public function testCreateBadDirectory()
+    {
+        new ResourceMirror(new EventDispatcher(), 'http://example.com/', '/a/probably/not/writable/directory');
+    }
 }
Test creating a mirror with a bad directory.