Conditions | 1 |
Paths | 1 |
Total Lines | 17 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
5 | public function testGet() |
||
6 | { |
||
7 | $aimeos = $this->app->make('\Aimeos\Shop\Base\Aimeos'); |
||
8 | |||
9 | $configMock = $this->getMockBuilder('\Illuminate\Config\Repository') |
||
10 | ->setMethods( array('get', 'has') )->getMock(); |
||
11 | |||
12 | $configMock->expects( $this->once() )->method('has') |
||
13 | ->will( $this->returnValue(true) ); |
||
14 | |||
15 | $configMock->expects( $this->exactly(3) )->method('get') |
||
16 | ->will( $this->onConsecutiveCalls( true, 'laravel:', array() ) ); |
||
17 | |||
18 | $object = new \Aimeos\Shop\Base\I18n($configMock, $aimeos); |
||
19 | $list = $object->get( array('en') ); |
||
20 | |||
21 | $this->assertInstanceOf( '\Aimeos\MW\Translation\Iface', $list['en'] ); |
||
22 | } |
||
24 |