You are here

public function SortsFieldTest::testSortsField in Search API sorts 8

Tests for the value object, with just a field.

File

tests/src/Unit/SortsFieldTest.php, line 18

Class

SortsFieldTest
Tests the sorts field.

Namespace

Drupal\Tests\search_api_sorts\Unit

Code

public function testSortsField() {
  $field = new SortsField('donkey');
  $this
    ->assertEquals('donkey', $field
    ->getFieldName());
  $this
    ->assertEquals('asc', $field
    ->getOrder());
}