You are here

ImceFolderTest.php in IMCE 8

Same filename in this branch
  1. 8 tests/src/Unit/ImceFolderTest.php
  2. 8 tests/src/Kernel/ImceFolderTest.php
Same filename and directory in other branches
  1. 8.2 tests/src/Unit/ImceFolderTest.php

File

tests/src/Unit/ImceFolderTest.php
View source
<?php

namespace Drupal\Tests\imce\Unit;

use Drupal\imce\ImceFolder;
use Drupal\Tests\UnitTestCase;

/**
 * Test ImceFile.
 *
 * @group imce
 */
class ImceFolderTest extends UnitTestCase {

  /**
   * The Imce Folder.
   *
   * @var \Drupal\imce\ImceFolder
   */
  protected $imceFolder;

  /**
   * {@inheritdoc}
   */
  public function setUp() {
    parent::setUp();
    $this->imceFolder = $this
      ->createMock(ImceFolder::class);
  }

  /**
   * Test type.
   */
  public function testType() {
    $this
      ->assertNotEmpty($this->imceFolder->type);
    $this
      ->assertTrue(is_string($this->imceFolder->type));
    $this
      ->assertEquals('folder', $this->imceFolder->type);
  }

}

Classes

Namesort descending Description
ImceFolderTest Test ImceFile.