Conditions | 1 |
Paths | 1 |
Total Lines | 25 |
Code Lines | 20 |
Lines | 0 |
Ratio | 0 % |
Tests | 19 |
CRAP Score | 1 |
Changes | 0 |
1 | <?php |
||
25 | 12 | public function getConfigTreeBuilder() |
|
26 | { |
||
27 | 12 | $treeBuilder = new TreeBuilder(); |
|
28 | 12 | $rootNode = $treeBuilder->root('vm_pro_api'); |
|
29 | |||
30 | $rootNode |
||
31 | 12 | ->children() |
|
32 | 12 | ->scalarNode('base_url') |
|
33 | 12 | ->defaultValue(self::DEFAULT_API_BASE_URL) |
|
34 | 12 | ->end() |
|
35 | 12 | ->integerNode('default_vm_id') |
|
36 | 12 | ->defaultValue(0) |
|
37 | 12 | ->end() |
|
38 | 12 | ->arrayNode('credentials') |
|
39 | 12 | ->isRequired() |
|
40 | 12 | ->children() |
|
41 | 12 | ->scalarNode('username')->isRequired()->end() |
|
42 | 12 | ->scalarNode('password')->isRequired()->end() |
|
43 | 12 | ->end() |
|
44 | 12 | ->end() |
|
45 | 12 | ->end() |
|
46 | ; |
||
47 | |||
48 | 12 | return $treeBuilder; |
|
49 | } |
||
50 | } |
||
51 |