mirror of
https://github.com/flextype/flextype.git
synced 2025-08-08 14:16:46 +02:00
feat(tests): add tests for MediaFolders create() method #477
This commit is contained in:
16
tests/Foundation/Media/MediaFoldersTest.php
Normal file
16
tests/Foundation/Media/MediaFoldersTest.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
beforeEach(function() {
|
||||
filesystem()->directory(PATH['project'] . '/uploads')->create();
|
||||
filesystem()->directory(PATH['project'] . '/uploads/.meta')->create();
|
||||
});
|
||||
|
||||
afterEach(function (): void {
|
||||
filesystem()->directory(PATH['project'] . '/uploads')->delete();
|
||||
});
|
||||
|
||||
test('test create() method', function () {
|
||||
$this->assertTrue(flextype('media_folders')->create('foo'));
|
||||
});
|
Reference in New Issue
Block a user