TYPO3 CMS  TYPO3_6-2
ReflectionServiceTest.php
Go to the documentation of this file.
1 <?php
3 
21 
26  public function fixtureMethodForMethodTagsValues(array $foo) {
27  }
28 
32  public function hasMethod() {
33  $service = new \TYPO3\CMS\Extbase\Reflection\ReflectionService();
34  $this->assertTrue($service->hasMethod(get_class($this), 'fixtureMethodForMethodTagsValues'));
35  $this->assertFalse($service->hasMethod(get_class($this), 'notExistentMethod'));
36  }
37 
41  public function getMethodTagsValues() {
42  $service = new \TYPO3\CMS\Extbase\Reflection\ReflectionService();
43  $tagsValues = $service->getMethodTagsValues(get_class($this), 'fixtureMethodForMethodTagsValues');
44  $this->assertEquals(array(
45  'param' => array('array $foo The foo parameter'),
46  'return' => array('void')
47  ), $tagsValues);
48  }
49 
53  public function getMethodParameters() {
54  $service = new \TYPO3\CMS\Extbase\Reflection\ReflectionService();
55  $parameters = $service->getMethodParameters(get_class($this), 'fixtureMethodForMethodTagsValues');
56  $this->assertEquals(array(
57  'foo' => array(
58  'position' => 0,
59  'byReference' => FALSE,
60  'array' => TRUE,
61  'optional' => FALSE,
62  'allowsNull' => FALSE,
63  'class' => NULL,
64  'type' => 'array'
65  )
66  ), $parameters);
67  }
68 }
$parameters
Definition: FileDumpEID.php:15