1 | <?php |
||
25 | class DocBlockTest extends TestCase |
||
26 | { |
||
27 | /** |
||
28 | * Call Mockery::close after each test. |
||
29 | */ |
||
30 | public function tearDown() |
||
34 | |||
35 | /** |
||
36 | * @covers ::__construct |
||
37 | * @covers ::getSummary |
||
38 | * |
||
39 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
40 | */ |
||
41 | public function testDocBlockCanHaveASummary() |
||
49 | |||
50 | /** |
||
51 | * @covers ::__construct |
||
52 | * |
||
53 | * @expectedException \InvalidArgumentException |
||
54 | */ |
||
55 | public function testExceptionIsThrownIfSummaryIsNotAString() |
||
59 | |||
60 | /** |
||
61 | * @covers ::__construct |
||
62 | * |
||
63 | * @expectedException \InvalidArgumentException |
||
64 | */ |
||
65 | public function testExceptionIsThrownIfTemplateStartIsNotABoolean() |
||
69 | |||
70 | /** |
||
71 | * @covers ::__construct |
||
72 | * |
||
73 | * @expectedException \InvalidArgumentException |
||
74 | */ |
||
75 | public function testExceptionIsThrownIfTemplateEndIsNotABoolean() |
||
79 | |||
80 | /** |
||
81 | * @covers ::__construct |
||
82 | * @covers ::getDescription |
||
83 | * |
||
84 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
85 | */ |
||
86 | public function testDocBlockCanHaveADescription() |
||
94 | |||
95 | /** |
||
96 | * @covers ::__construct |
||
97 | * @covers ::getTags |
||
98 | * |
||
99 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
100 | * @uses \phpDocumentor\Reflection\DocBlock\Tag |
||
101 | */ |
||
102 | public function testDocBlockCanHaveTags() |
||
112 | |||
113 | /** |
||
114 | * @covers ::__construct |
||
115 | * @covers ::getTags |
||
116 | * |
||
117 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
118 | * @uses \phpDocumentor\Reflection\DocBlock\Tag |
||
119 | * |
||
120 | * @expectedException \InvalidArgumentException |
||
121 | */ |
||
122 | public function testDocBlockAllowsOnlyTags() |
||
130 | |||
131 | /** |
||
132 | * @covers ::__construct |
||
133 | * @covers ::getTagsByName |
||
134 | * |
||
135 | * @uses \phpDocumentor\Reflection\DocBlock::getTags |
||
136 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
137 | * @uses \phpDocumentor\Reflection\DocBlock\Tag |
||
138 | */ |
||
139 | public function testFindTagsInDocBlockByName() |
||
155 | |||
156 | /** |
||
157 | * @covers ::__construct |
||
158 | * @covers ::getTagsByName |
||
159 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
160 | * @expectedException \InvalidArgumentException |
||
161 | */ |
||
162 | public function testExceptionIsThrownIfNameForTagsIsNotString() |
||
167 | |||
168 | /** |
||
169 | * @covers ::__construct |
||
170 | * @covers ::hasTag |
||
171 | * |
||
172 | * @uses \phpDocumentor\Reflection\DocBlock::getTags |
||
173 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
174 | * @uses \phpDocumentor\Reflection\DocBlock\Tag |
||
175 | */ |
||
176 | public function testCheckIfThereAreTagsWithAGivenName() |
||
192 | |||
193 | /** |
||
194 | * @covers ::__construct |
||
195 | * @covers ::hasTag |
||
196 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
197 | * @expectedException \InvalidArgumentException |
||
198 | */ |
||
199 | public function testExceptionIsThrownIfNameForCheckingTagsIsNotString() |
||
204 | |||
205 | /** |
||
206 | * @covers ::__construct |
||
207 | * @covers ::getContext |
||
208 | * |
||
209 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
210 | * @uses \phpDocumentor\Reflection\Types\Context |
||
211 | */ |
||
212 | public function testDocBlockKnowsInWhichNamespaceItIsAndWhichAliasesThereAre() |
||
220 | |||
221 | /** |
||
222 | * @covers ::__construct |
||
223 | * @covers ::getLocation |
||
224 | * |
||
225 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
226 | * @uses \phpDocumentor\Reflection\Location |
||
227 | */ |
||
228 | public function testDocBlockKnowsAtWhichLineItIs() |
||
236 | |||
237 | /** |
||
238 | * @covers ::__construct |
||
239 | * @covers ::isTemplateStart |
||
240 | * |
||
241 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
242 | */ |
||
243 | public function testDocBlockKnowsIfItIsTheStartOfADocBlockTemplate() |
||
249 | |||
250 | /** |
||
251 | * @covers ::__construct |
||
252 | * @covers ::isTemplateEnd |
||
253 | * |
||
254 | * @uses \phpDocumentor\Reflection\DocBlock\Description |
||
255 | */ |
||
256 | public function testDocBlockKnowsIfItIsTheEndOfADocBlockTemplate() |
||
262 | |||
263 | /** |
||
264 | * @covers ::__construct |
||
265 | * @covers ::removeTag |
||
266 | * |
||
267 | * @uses \phpDocumentor\Reflection\DocBlock\Tags\Deprecated |
||
268 | */ |
||
269 | public function testRemoveTag() |
||
286 | } |
||
287 |