You are here

public function CurrencyTest::testGetValueOptions in Currency 8.3

@covers ::getValueOptions

File

tests/src/Unit/Plugin/views/filter/CurrencyTest.php, line 68

Class

CurrencyTest
@coversDefaultClass \Drupal\currency\Plugin\views\filter\Currency

Namespace

Drupal\Tests\currency\Unit\Plugin\views\filter

Code

public function testGetValueOptions() {
  $options = array(
    $this
      ->randomMachineName() => $this
      ->randomMachineName(),
  );
  $this->formHelper
    ->expects($this
    ->atLeastOnce())
    ->method('getCurrencyOptions')
    ->willReturn($options);
  $method = new \ReflectionMethod($this->sut, 'getValueOptions');
  $method
    ->setAccessible(TRUE);
  $this
    ->assertSame($options, $method
    ->invoke($this->sut));
}