Passed
Push — master ( 94cd2d...fa1d41 )
by Aimeos
02:24
created

StandardTest::setUp()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 2
c 1
b 0
f 0
dl 0
loc 4
rs 10
cc 1
nc 1
nop 0
1
<?php
2
3
namespace Aimeos\Base\Filesystem\Manager;
4
5
6
class StandardTest extends \PHPUnit\Framework\TestCase
7
{
8
	public function testGet()
9
	{
10
		$config = \TestHelper::getConfig()->get( 'resource' );
11
		$config['fs-media'] = [
12
			'adapter' => 'Standard',
13
			'basedir' => __DIR__
14
		];
15
16
		$object = new \Aimeos\Base\Filesystem\Manager\Standard( $config );
17
18
		$this->assertInstanceof( 'Aimeos\Base\Filesystem\Iface', $object->get( 'fs-media' ) );
19
	}
20
21
22
	public function testGetFallback()
23
	{
24
		$config = \TestHelper::getConfig()->get( 'resource' );
25
		$config['fs'] = [
26
			'adapter' => 'Standard',
27
			'basedir' => __DIR__
28
		];
29
30
		$object = new \Aimeos\Base\Filesystem\Manager\Standard( $config );
31
32
		$this->assertInstanceof( 'Aimeos\Base\Filesystem\Iface', $object->get( 'fs-media' ) );
33
	}
34
}
35