Code Duplication    Length = 14-14 lines in 2 locations

tests/PageControllerTemplateOverrideExtensionTest.php 2 locations

@@ 7-20 (lines=14) @@
4
5
	protected static $fixture_file = 'template-override/tests/pages.yml';
6
7
	public function testLayoutTemplateOveride() {
8
		$this->logInWithPermission('ADMIN');
9
		$page = $this->objFromFixture('Page', 'page1');
10
		$page->AlternativeTemplate = 'PageInnerTest';
11
		$page->write();
12
		$page->doPublish();
13
		$response = $this->get('/' . $page->URLSegment);
14
		$this->assertEquals(200, $response->getStatusCode());
15
16
		// assert the the inner layout template has been used
17
		$this->assertExactMatchBySelector("div.marker", array(
18
			"INNER LAYOUT"
19
		));
20
	}
21
22
23
	public function testOuterTemplateOveride() {
@@ 23-36 (lines=14) @@
20
	}
21
22
23
	public function testOuterTemplateOveride() {
24
		$this->logInWithPermission('ADMIN');
25
		$page = $this->objFromFixture('Page', 'page1');
26
		$page->AlternativeTemplate = 'PageOuterTest';
27
		$page->write();
28
		$page->doPublish();
29
		$response = $this->get('/' . $page->URLSegment);
30
		$this->assertEquals(200, $response->getStatusCode());
31
32
		// show the the outer layout template has been used
33
		$this->assertExactMatchBySelector("div.marker", array(
34
			"OUTER OF LAYOUT"
35
		));
36
	}
37
38
39
	public function testNoTemplateOverride() {