Completed
Push — develop ( 28aa0b...3fae3c )
by Jaap
13s
created

TestCase::tearDown()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 4
rs 10
c 0
b 0
f 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\Php\Factory;
14
15
use Mockery as m;
16
use phpDocumentor\Reflection\Php\ProjectFactoryStrategy;
17
use phpDocumentor\Reflection\Php\StrategyContainer;
18
use phpDocumentor\Reflection\Types\Context;
19
use PHPUnit\Framework\TestCase as BaseTestCase;
20
21
/**
22
 * Base test case for all strategies, to be sure that they check if the can handle objects before handeling them.
23
 */
24
abstract class TestCase extends BaseTestCase
25
{
26
    /**
27
     * @var ProjectFactoryStrategy
28
     */
29
    protected $fixture;
30
31
    protected function tearDown()
32
    {
33
        m::close();
34
    }
35
36
    /**
37
     * @covers ::create
38
     *
39
     * @expectedException \InvalidArgumentException
40
     */
41
    public function testCreateThrowsException()
42
    {
43
        $this->fixture->create(new \stdClass(), m::mock(StrategyContainer::class));
44
    }
45
}
46