for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Redaxscript\Tests\Admin\Html;
use Redaxscript\Admin;
use Redaxscript\Tests\TestCaseAbstract;
/**
* FormTest
*
* @since 3.0.0
* @package Redaxscript
* @category Tests
* @author Henry Ruhs
* @covers Redaxscript\Admin\Html\Form
*/
class FormTest extends TestCaseAbstract
{
* setUp
* @since 3.1.0
public function setUp() : void
parent::setUp();
$optionArray = $this->getOptionArray();
$installer = $this->installerFactory();
$installer->init();
$installer->rawCreate();
$installer->insertSettings($optionArray);
}
* tearDown
public function tearDown() : void
$this->dropDatabase();
* testCreate
* @param array $attributeArray
* @param array $optionArray
* @param string $expect
* @dataProvider providerAutoloader
public function testCreate(array $attributeArray = [], array $optionArray = [], string $expect = null) : void
/* setup */
$form = new Admin\Html\Form($this->_registry, $this->_language);
$form->init($attributeArray, $optionArray);
/* actual */
$actual = $form;
/* compare */
$this->assertEquals($expect, $actual);