Passed
Push — master ( c1ea42...932af5 )
by David
43s
created

DoctrineAnnotationDumperTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 2
dl 0
loc 12
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A testExportValues() 0 8 1
1
<?php
2
3
namespace TheCodingMachine\FluidSchema;
4
5
use PHPUnit\Framework\TestCase;
6
7
class DoctrineAnnotationDumperTest extends TestCase
8
{
9
10
    public function testExportValues()
11
    {
12
        $this->assertSame('', DoctrineAnnotationDumper::exportValues(null));
13
        $this->assertSame('({})', DoctrineAnnotationDumper::exportValues([]));
14
        $this->assertSame('("foo")', DoctrineAnnotationDumper::exportValues("foo"));
15
        $this->assertSame('(foo = "bar")', DoctrineAnnotationDumper::exportValues(["foo"=>"bar"]));
16
        $this->assertSame('(foo = {"bar":"baz", "baz":"bar"})', DoctrineAnnotationDumper::exportValues(["foo"=>["bar"=>"baz","baz"=>"bar"]]));
17
    }
18
}
19