Conditions | 2 |
Paths | 2 |
Total Lines | 15 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
1 | <?php |
||
5 | public function testUpdateCMSFields() { |
||
6 | $layer = new PointsOfInterestLayer(); |
||
7 | $fields = $layer->getCMSFields(); |
||
8 | $root = $fields->fieldByName('Root.Main'); |
||
9 | $fields = $root->FieldList(); |
||
10 | $names = array(); |
||
11 | foreach ($fields as $field) { |
||
12 | $names[] = $field->getName(); |
||
13 | } |
||
14 | |||
15 | error_log(print_r($names,1)); |
||
16 | $expected = array('Name', 'ShowGuideMarkers', 'DefaultIcon'); |
||
17 | $this->assertEquals($expected, $names); |
||
1 ignored issue
–
show
|
|||
18 | |||
19 | } |
||
20 | |||
25 | } |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.