Completed
Push — master ( d12968...2a6550 )
by Harry
02:36
created

StringTokeniserTest::tokeniserTestData()   B

Complexity

Conditions 1
Paths 1

Size

Total Lines 110
Code Lines 90

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 110
rs 8.2857
cc 1
eloc 90
nc 1
nop 0

How to fix   Long Method   

Long Method

Small methods make your code easier to understand, in particular if combined with a good name. Besides, if your method is small, finding a good name is usually much easier.

For example, if you find yourself adding comments to a method's body, this is usually a good sign to extract the commented part to a new method, and use the comment as a starting point when coming up with a good name for this new method.

Commonly applied refactorings include:

1
<?php
2
3
namespace Graze\CsvToken\Test\Unit;
4
5
use Graze\CsvToken\Csv\CsvConfiguration;
6
use Graze\CsvToken\Test\TestCase;
7
use Graze\CsvToken\Tokeniser\StreamTokeniser;
8
use Graze\CsvToken\Tokeniser\StringTokeniser;
9
use Graze\CsvToken\Tokeniser\TokeniserInterface;
10
11
class StringTokeniserTest extends TestCase
12
{
13
    public function testInstanceOf()
14
    {
15
        $tokeniser = new StringTokeniser(new CsvConfiguration(), '"test","data"');
16
17
        static::assertInstanceOf(StreamTokeniser::class, $tokeniser);
18
        static::assertInstanceOf(TokeniserInterface::class, $tokeniser);
19
    }
20
}
21