Completed
Push — master ( 3ef4f5...a11ba3 )
by Jeroen De
02:21
created

testListParamProcessingWithEmptyListAsDefault()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 9
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 9
rs 9.6666
cc 1
eloc 6
nc 1
nop 0
1
<?php
2
3
namespace ParamProcessor\Tests;
4
5
use ParamProcessor\Options;
6
use ParamProcessor\Param;
7
use ParamProcessor\ParamDefinition;
8
9
/**
10
 * @covers ParamProcessor\Param
11
 *
12
 * @licence GNU GPL v2+
13
 * @author Jeroen De Dauw < [email protected] >
14
 */
15
class ParamTest extends \PHPUnit_Framework_TestCase {
16
17
	public function testListParamProcessingWithEmptyListAsDefault() {
18
		$definition = new ParamDefinition( 'string', 'something', [] );
19
		$definitions = [ $definition ];
20
21
		$param = new Param( $definition );
22
		$param->process( $definitions, [], new Options() );
23
24
		$this->assertSame( [], $param->getValue() );
25
	}
26
27
}
28