]> source.dussan.org Git - nextcloud-server.git/commitdiff
Make sure tests cover the new mkdir behaviour on 0 quota
authorJulius Härtl <jus@bitgrid.net>
Tue, 8 Sep 2020 09:35:32 +0000 (11:35 +0200)
committerJulius Härtl <jus@bitgrid.net>
Tue, 8 Sep 2020 09:35:32 +0000 (11:35 +0200)
Signed-off-by: Julius Härtl <jus@bitgrid.net>
tests/lib/Files/Storage/Wrapper/QuotaTest.php

index 65cfe30eb1c58fdf584733c379ac30ddcaf5ab56..651ee975ab2d6e120dde3ee0614941f280d54901 100644 (file)
@@ -211,7 +211,17 @@ class QuotaTest extends \Test\Files\Storage\Storage {
 
        public function testNoMkdirQuotaZero() {
                $instance = $this->getLimitedStorage(0.0);
-               $this->assertFalse($instance->mkdir('foobar'));
+               $this->assertFalse($instance->mkdir('files'));
+               $this->assertFalse($instance->mkdir('files/foobar'));
+       }
+
+       public function testMkdirQuotaZeroTrashbin() {
+               $instance = $this->getLimitedStorage(0.0);
+               $this->assertTrue($instance->mkdir('files_trashbin'));
+               $this->assertTrue($instance->mkdir('files_trashbin/files'));
+               $this->assertTrue($instance->mkdir('files_versions'));
+               $this->assertTrue($instance->mkdir('cache'));
+
        }
 
        public function testNoTouchQuotaZero() {