public function testGetJsLayout()
 {
     $this->layoutProcessorMock->expects($this->once())->method('process')->with($this->jsLayout)->willReturnArgument(0);
     $this->jsonEncoderMock->expects($this->once())->method('encode')->with($this->jsLayout)->willReturnArgument(0);
     $this->assertEquals($this->jsLayout, $this->model->getJsLayout());
 }
Exemplo n.º 2
0
 /**
  * Retrieve gift message configuration
  *
  * @return array
  */
 public function getGiftOptionsConfigJson()
 {
     return $this->jsonEncoder->encode($this->configProvider->getConfig());
 }
Exemplo n.º 3
0
 /**
  * Retrieve checkout configuration
  *
  * @return array
  * @codeCoverageIgnore
  */
 public function getCheckoutConfig()
 {
     return $this->configProvider->getConfig();
 }
 public function testGetConfig()
 {
     $config = ['key' => 'value'];
     $this->configProviderMock->expects($this->once())->method('getConfig')->willReturn($config);
     $this->assertEquals($config, $this->model->getConfig());
 }