You are here

ProfileTest.php in Linkit 8.5

File

tests/src/Kernel/Entity/ProfileTest.php
View source
<?php

namespace Drupal\Tests\linkit\Kernel\Entity;

use Drupal\linkit\Tests\ProfileCreationTrait;
use Drupal\Tests\linkit\Kernel\LinkitKernelTestBase;

/**
 * Tests the Profile entity.
 *
 * @coversDefaultClass \Drupal\linkit\Entity\Profile
 *
 * @group linkit
 */
class ProfileTest extends LinkitKernelTestBase {
  use ProfileCreationTrait;

  /**
   * Test the profile description.
   *
   * @covers ::getDescription
   * @covers ::setDescription
   */
  public function testDescription() {
    $profile = $this
      ->createProfile([
      'description' => 'foo',
    ]);
    $this
      ->assertEquals('foo', $profile
      ->getDescription());
    $profile
      ->setDescription('bar');
    $this
      ->assertEquals('bar', $profile
      ->getDescription());
  }

}

Classes

Namesort descending Description
ProfileTest Tests the Profile entity.