for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* Spiral Framework.
*
* @license MIT
* @author Anton Titov (Wolfy-J)
*/
declare(strict_types=1);
namespace Spiral\Tests\Config;
use Spiral\Config\Patch\Set;
class SetTest extends BaseTest
{
public function testPatch(): void
$cf = $this->getFactory();
$this->assertEquals(['value' => 'value!'], $cf->getConfig('scope'));
$cf->modify('scope', new Set('value', 'x'));
$this->assertSame([
'value' => 'x',
], $cf->getConfig('scope'));
$cf->modify('scope', new Set('value', 'y'));
'value' => 'y',
}