Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
Public Member Functions
ReaderTest Class Reference
Inheritance diagram for ReaderTest:

Public Member Functions

 setUp ()
 
 testRead ()
 

Detailed Description

Definition at line 13 of file ReaderTest.php.

Member Function Documentation

◆ setUp()

setUp ( )

Definition at line 25 of file ReaderTest.php.

26  {
27  $this->source = $this->getMockBuilder(SourceInterface::class)
28  ->getMockForAbstractClass();
29  $this->reader = new Reader([['class' => $this->source]]);
30  }

◆ testRead()

testRead ( )

Definition at line 32 of file ReaderTest.php.

33  {
34  $config = [
35  'default' => [
36  'general/locale/code'=> 'ru_RU',
37  'general/locale/timezone'=> 'America/Chicago',
38  ]
39  ];
40  $this->source->expects($this->once())
41  ->method('get')
42  ->with(null)
43  ->willReturn($config);
44  $this->assertEquals($config, $this->reader->read());
45  }
$config
Definition: fraud_order.php:17

The documentation for this class was generated from the following file: