You are here

public function ImageUtilityTest::testPercentFilter in Image Effects 8

Same name and namespace in other branches
  1. 8.3 tests/src/Unit/ImageUtilityTest.php \Drupal\Tests\image_effects\Unit\ImageUtilityTest::testPercentFilter()
  2. 8.2 tests/src/Unit/ImageUtilityTest.php \Drupal\Tests\image_effects\Unit\ImageUtilityTest::testPercentFilter()

@covers ::percentFilter @dataProvider percentFilterProvider

File

tests/src/Unit/ImageUtilityTest.php, line 40

Class

ImageUtilityTest
Tests the image utility helper methods.

Namespace

Drupal\Tests\image_effects\Unit

Code

public function testPercentFilter($length_specification, $current_length, $expected_result) {
  $this
    ->assertSame($expected_result, ImageUtility::percentFilter($length_specification, $current_length));
}