public function HidePreviewTest::testMultiline2Array in Hide Preview Button 8
Tests that the multiline2Array method returns the right amount of values.
File
- src/
tests/ src/ Unit/ HidePreviewTest.php, line 43
Class
- HidePreviewTest
- Tests some functions of the Hide Preview module.
Namespace
Drupal\Tests\phpunit_example\UnitCode
public function testMultiline2Array() {
$multiline = "value1\r\nvalue2\r\nvalue3";
$array = $this->configForm
->multiline2Array($multiline);
$this
->assertEquals(3, count($array));
}