Completed
Pull Request — master (#15)
by John
02:38
created

StaticGraphicParserTest   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A setUp() 0 10 1
A testGetGraphic() 0 4 1
1
<?php
2
3
namespace Graze\CiffRenderer\Test;
4
5
use Graze\CiffRenderer\Field\Parser\StaticGraphicParser;
6
7
class StaticGraphicParserTest extends \PHPUnit_Framework_TestCase
8
{
9
    protected $parser;
10
11
    public function setUp()
12
    {
13
        $pathToFixture = sprintf('%s/Fixture/StaticGraphicParserFixture.xml', dirname(__FILE__));
14
15
        $xml = simplexml_load_file($pathToFixture);
16
17
        $this->parser = new StaticGraphicParser();
18
19
        $this->parser->setXmlField($xml);
20
    }
21
22
    public function testGetGraphic()
23
    {
24
        $this->assertEquals('w:/example.bmp', $this->parser->getGraphic());
25
    }
26
}
27