Completed
Pull Request — develop (#89)
by Jaap
02:41
created

LocalFileTest::testPath()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %
Metric Value
dl 0
loc 5
rs 9.4286
cc 1
eloc 3
nc 1
nop 0
1
<?php
2
/**
3
 * This file is part of phpDocumentor.
4
 *
5
 * For the full copyright and license information, please view the LICENSE
6
 * file that was distributed with this source code.
7
 *
8
 * @copyright 2010-2015 Mike van Riel<[email protected]>
9
 * @license   http://www.opensource.org/licenses/mit-license.php MIT
10
 * @link      http://phpdoc.org
11
 */
12
13
namespace phpDocumentor\Reflection\File;
14
15
/**
16
 * @coversDefaultClass phpDocumentor\Reflection\File\LocalFile
17
 * @covers ::__construct
18
 */
19
class LocalFileTest extends \PHPUnit_Framework_TestCase
20
{
21
    /**
22
     * @covers ::getContents
23
     */
24
    public function testGetContents()
25
    {
26
        $file = new LocalFile(__FILE__);
27
        $this->assertEquals(file_get_contents(__FILE__), $file->getContents());
28
    }
29
30
    /**
31
     * @covers ::md5
32
     */
33
    public function testMd5()
34
    {
35
        $file = new LocalFile(__FILE__);
36
        $this->assertEquals(md5_file(__FILE__), $file->md5());
37
    }
38
39
    /**
40
     * @covers ::path
41
     */
42
    public function testPath()
43
    {
44
        $file = new LocalFile(__FILE__);
45
        $this->assertEquals(__FILE__, $file->path());
46
    }
47
}
48