@@ 31-45 (lines=15) @@ | ||
28 | /** |
|
29 | * testShouldReturnNameForEntityWhenNoSEO |
|
30 | */ |
|
31 | public function testShouldReturnNameForEntityWhenNoSEO() |
|
32 | { |
|
33 | $name = 'OK'; |
|
34 | ||
35 | $this->entityWithName($name); |
|
36 | $this->noSeoFound(); |
|
37 | ||
38 | $object = new SeoTwigExtension($this->emMock); |
|
39 | ||
40 | ||
41 | $result = $object->getTitleFor($this->entityMock); |
|
42 | ||
43 | ||
44 | $this->assertEquals($name, $result); |
|
45 | } |
|
46 | ||
47 | /** |
|
48 | * testShouldReturnNameForEntityWhenSEOWithTitleFound |
|
@@ 50-65 (lines=16) @@ | ||
47 | /** |
|
48 | * testShouldReturnNameForEntityWhenSEOWithTitleFound |
|
49 | */ |
|
50 | public function testShouldReturnNameForEntityWhenSEOWithTitleFound() |
|
51 | { |
|
52 | $nokName = 'NOK'; |
|
53 | $name = 'OK'; |
|
54 | ||
55 | $this->entityWithName($nokName); |
|
56 | $this->seoFoundWithTitle($name); |
|
57 | ||
58 | $object = new SeoTwigExtension($this->emMock); |
|
59 | ||
60 | ||
61 | $result = $object->getTitleFor($this->entityMock); |
|
62 | ||
63 | ||
64 | $this->assertEquals($name, $result); |
|
65 | } |
|
66 | ||
67 | /** |
|
68 | * @param string $name |