1 | <?php |
||
2 | |||
3 | namespace Doctrine\Tests\DBAL\Functional\Ticket; |
||
4 | |||
5 | use Doctrine\DBAL\Schema\SQLServerSchemaManager; |
||
6 | use Doctrine\DBAL\Types\DecimalType; |
||
7 | |||
8 | /** |
||
9 | * @group DBAL-461 |
||
10 | */ |
||
11 | class DBAL461Test extends \PHPUnit\Framework\TestCase |
||
12 | { |
||
13 | public function testIssue() |
||
14 | { |
||
15 | $conn = $this->createMock('Doctrine\DBAL\Connection'); |
||
16 | $platform = $this->getMockForAbstractClass('Doctrine\DBAL\Platforms\AbstractPlatform'); |
||
17 | $platform->registerDoctrineTypeMapping('numeric', 'decimal'); |
||
1 ignored issue
–
show
|
|||
18 | |||
19 | $schemaManager = new SQLServerSchemaManager($conn, $platform); |
||
20 | |||
21 | $reflectionMethod = new \ReflectionMethod($schemaManager, '_getPortableTableColumnDefinition'); |
||
22 | $reflectionMethod->setAccessible(true); |
||
23 | $column = $reflectionMethod->invoke($schemaManager, array( |
||
24 | 'type' => 'numeric(18,0)', |
||
25 | 'length' => null, |
||
26 | 'default' => null, |
||
27 | 'notnull' => false, |
||
28 | 'scale' => 18, |
||
29 | 'precision' => 0, |
||
30 | 'autoincrement' => false, |
||
31 | 'collation' => 'foo', |
||
32 | 'comment' => null, |
||
33 | )); |
||
34 | |||
35 | $this->assertInstanceOf(DecimalType::class, $column->getType()); |
||
36 | } |
||
37 | } |
||
38 |
This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.
This is most likely a typographical error or the method has been renamed.