blob: d08523908c025a9781d7737d4c79175091ab3d25 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
<?php
namespace SMW\Tests\SQLStore\QueryEngine;
use SMW\SQLStore\QueryEngine\DescriptionInterpreterFactory;
/**
* @covers \SMW\SQLStore\QueryEngine\DescriptionInterpreterFactory
* @group semantic-mediawiki
*
* @license GNU GPL v2+
* @since 2.4
*
* @author mwjames
*/
class DescriptionInterpreterFactoryTest extends \PHPUnit_Framework_TestCase {
public function testCanConstruct() {
$this->assertInstanceOf(
'\SMW\SQLStore\QueryEngine\DescriptionInterpreterFactory',
new DescriptionInterpreterFactory()
);
}
public function testCanConstructDispatchingDescriptionInterpreter() {
$querySegmentListBuilder = $this->getMockBuilder( '\SMW\SQLStore\QueryEngine\QuerySegmentListBuilder' )
->disableOriginalConstructor()
->getMock();
$instance = new DescriptionInterpreterFactory();
$this->assertInstanceOf(
'\SMW\SQLStore\QueryEngine\DescriptionInterpreters\DispatchingDescriptionInterpreter',
$instance->newDispatchingDescriptionInterpreter( $querySegmentListBuilder )
);
}
}
|