public function testProcess()
 {
     $data = ['web' => ['unsecure' => ['base_url' => 'http://localhost/', 'base_link_url' => '{{unsecure_base_url}}website/de'], 'secure' => ['base_url' => 'https://localhost/', 'base_link_url' => '{{secure_base_url}}website/de']], 'path' => 'value', 'some_url' => '{{base_url}}some'];
     $expectedResult = $data;
     $expectedResult['web']['unsecure']['base_link_url'] = 'http://localhost/website/de';
     $expectedResult['web']['secure']['base_link_url'] = 'https://localhost/website/de';
     $expectedResult['some_url'] = 'http://localhost/some';
     $this->assertEquals($expectedResult, $this->_model->process($data));
 }
示例#2
0
 /**
  * Convert config data
  *
  * @param array $source
  * @param array $initialConfig
  * @return array
  */
 public function convert($source, $initialConfig = [])
 {
     $config = array_replace_recursive($initialConfig, parent::convert($source));
     return $this->_processor->process($config);
 }