Passed
Push — main ( 40d4d0...b1f2dd )
by N.
05:04
created

MatcherTest::testCreateObject()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 10
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 6
nc 1
nop 0
dl 0
loc 10
rs 10
c 0
b 0
f 0
1
<?php
2
3
/**
4
 * Klass MatcherTest.
5
 * @author Niklas Dougherty
6
 */
7
8
declare(strict_types=1);
9
10
namespace Tips\Tests\Klasser;
11
12
use PHPUnit\Framework\TestCase;
13
use Tips\Klasser\Spel;
14
use Tips\Klasser\Preludium;
15
use Tips\Klasser\Matcher;
16
17
/**
18
 * Klass MatcherTest.
19
 * @covers \Tips\Tests\Klasser
20
 */
21
class MatcherTest extends TestCase
22
{
23
	/**
24
	 * Construct object with argument and verify that the object has the expected properties.
25
	 */
26
	public function testCreateObject(): void
27
	{
28
		new Preludium();
29
//		$this->assertInstanceOf("\Tips\Klasser\Omgang", new Omgang());
30
		$this->assertInstanceOf("\Tips\Klasser\Spel", $spel = new Spel());
31
		$this->assertInstanceOf("\Tips\Klasser\Matcher", $matcher = new Matcher($spel));
32
		$matcher->hämta_matcher();
33
34
		$this->assertObjectHasProperty('filnamn', $spel);
35
		$this->assertTrue($spel->omgång_existerar($spel->omgång));
36
	}
37
}
38