PyStringNodeTest   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A testGetStrings() 0 6 1
A testGetRaw() 0 11 1
1
<?php
2
3
namespace Tests\Behat\Gherkin\Node;
4
5
use Behat\Gherkin\Node\PyStringNode;
6
use PHPUnit\Framework\TestCase;
7
8
class PyStringNodeTest extends TestCase
9
{
10
    public function testGetStrings()
11
    {
12
        $str = new PyStringNode(array('line1', 'line2', 'line3'), 0);
13
14
        $this->assertEquals(array('line1', 'line2', 'line3'), $str->getStrings());
15
    }
16
17
    public function testGetRaw()
18
    {
19
        $str = new PyStringNode(array('line1', 'line2', 'line3'), 0);
20
21
        $expected = <<<STR
22
line1
23
line2
24
line3
25
STR;
26
        $this->assertEquals($expected, $str->getRaw());
27
    }
28
}
29