Code Duplication    Length = 8-8 lines in 4 locations

admin/jsonadm/tests/Admin/JsonAdm/FactoryTest.php 4 locations

@@ 14-21 (lines=8) @@
11
12
class FactoryTest extends \PHPUnit_Framework_TestCase
13
{
14
	public function testCreateClient()
15
	{
16
		$context = \TestHelperJadm::getContext();
17
		$templatePaths = \TestHelperJadm::getJsonadmPaths();
18
19
		$client = \Aimeos\Admin\JsonAdm\Factory::createClient( $context, $templatePaths, 'order' );
20
		$this->assertInstanceOf( '\\Aimeos\\Admin\\JsonAdm\\Common\\Iface', $client );
21
	}
22
23
24
	public function testCreateSubClient()
@@ 24-31 (lines=8) @@
21
	}
22
23
24
	public function testCreateSubClient()
25
	{
26
		$context = \TestHelperJadm::getContext();
27
		$templatePaths = \TestHelperJadm::getJsonadmPaths();
28
29
		$client = \Aimeos\Admin\JsonAdm\Factory::createClient( $context, $templatePaths, 'order/base' );
30
		$this->assertInstanceOf( '\\Aimeos\\Admin\\JsonAdm\\Common\\Iface', $client );
31
	}
32
33
34
	public function testCreateClientEmpty()
@@ 34-41 (lines=8) @@
31
	}
32
33
34
	public function testCreateClientEmpty()
35
	{
36
		$context = \TestHelperJadm::getContext();
37
		$templatePaths = \TestHelperJadm::getJsonadmPaths();
38
39
		$client = \Aimeos\Admin\JsonAdm\Factory::createClient( $context, $templatePaths, '' );
40
		$this->assertInstanceOf( '\\Aimeos\\Admin\\JsonAdm\\Common\\Iface', $client );
41
	}
42
43
44
	public function testCreateClientInvalidPath()
@@ 44-51 (lines=8) @@
41
	}
42
43
44
	public function testCreateClientInvalidPath()
45
	{
46
		$context = \TestHelperJadm::getContext();
47
		$templatePaths = \TestHelperJadm::getJsonadmPaths();
48
49
		$this->setExpectedException( '\\Aimeos\\Admin\\JsonAdm\\Exception' );
50
		\Aimeos\Admin\JsonAdm\Factory::createClient( $context, $templatePaths, '%^' );
51
	}
52
53
54
	public function testCreateClientInvalidName()