public function TocFormatterTest::testConvertNumberToListTypeValue in TOC API 8
Tests converting number to list style type with TocFormatter::convertNumberToListTypeValue().
@dataProvider providerConvertNumberToListTypeValue
Parameters
int $number: The number to run through TocFormatter::convertNumberToListTypeValue().
string $type: The type to run through $this->formatter->convertNumberToListTypeValue().
string $expected: The expected result from calling the function.
See also
TocFormatter::convertNumberToListTypeValue()
File
- tests/
src/ Unit/ TocFormatterTest.php, line 83 - Contains \Drupal\Tests\toc_api\Unit\TocFormatterTest.
Class
- TocFormatterTest
- Tests TOC API formatter.
Namespace
Drupal\Tests\toc_api\UnitCode
public function testConvertNumberToListTypeValue($number, $type, $expected) {
$result = $this->formatter
->convertNumberToListTypeValue($number, $type);
$this
->assertEquals($expected, $result);
}