Skip to content

Commit

Permalink
Merge pull request #3002 from carusogabriel/missing-annotations
Browse files Browse the repository at this point in the history
Use @var instead of @param
  • Loading branch information
Ocramius committed Feb 6, 2018
2 parents 4ea3b4d + 3796bd2 commit ec85e54
Show file tree
Hide file tree
Showing 28 changed files with 178 additions and 49 deletions.
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DBAL/ConnectionTest.php
Expand Up @@ -30,6 +30,9 @@ class ConnectionTest extends \Doctrine\Tests\DbalTestCase
*/
protected $_conn = null;

/**
* @var string[]
*/
protected $params = array(
'driver' => 'pdo_mysql',
'host' => 'localhost',
Expand Down
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DBAL/Functional/DataAccessTest.php
Expand Up @@ -11,6 +11,9 @@

class DataAccessTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
/**
* @var bool
*/
static private $generated = false;

protected function setUp()
Expand Down
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DBAL/Functional/ModifyLimitQueryTest.php
Expand Up @@ -4,6 +4,9 @@

class ModifyLimitQueryTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
/**
* @var bool
*/
private static $tableCreated = false;

protected function setUp()
Expand Down
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DBAL/Functional/PortabilityTest.php
Expand Up @@ -13,6 +13,9 @@
*/
class PortabilityTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
/**
* @var Connection
*/
private $portableConnection;

protected function tearDown()
Expand Down
10 changes: 9 additions & 1 deletion tests/Doctrine/Tests/DBAL/Functional/ResultCacheTest.php
Expand Up @@ -4,13 +4,21 @@

use Doctrine\DBAL\Cache\QueryCacheProfile;
use Doctrine\DBAL\FetchMode;
use Doctrine\DBAL\Logging\DebugStack;

/**
* @group DDC-217
*/
class ResultCacheTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
/**
* @var int[][]|string[][]
*/
private $expectedResult = array(array('test_int' => 100, 'test_string' => 'foo'), array('test_int' => 200, 'test_string' => 'bar'), array('test_int' => 300, 'test_string' => 'baz'));

/**
* @var DebugStack
*/
private $sqlLogger;

protected function setUp()
Expand All @@ -30,7 +38,7 @@ protected function setUp()
}

$config = $this->_conn->getConfiguration();
$config->setSQLLogger($this->sqlLogger = new \Doctrine\DBAL\Logging\DebugStack);
$config->setSQLLogger($this->sqlLogger = new DebugStack);

$cache = new \Doctrine\Common\Cache\ArrayCache;
$config->setResultCacheImpl($cache);
Expand Down
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DBAL/Functional/TableGeneratorTest.php
Expand Up @@ -9,6 +9,9 @@
*/
class TableGeneratorTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
/**
* @var TableGenerator
*/
private $generator;

protected function setUp()
Expand Down
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DBAL/Functional/Ticket/DBAL630Test.php
Expand Up @@ -11,6 +11,9 @@
*/
class DBAL630Test extends \Doctrine\Tests\DbalFunctionalTestCase
{
/**
* @var bool
*/
private $running = false;

protected function setUp()
Expand Down
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DBAL/Functional/TypeConversionTest.php
Expand Up @@ -6,6 +6,9 @@

class TypeConversionTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
/**
* @var int
*/
static private $typeCounter = 0;

protected function setUp()
Expand Down
4 changes: 3 additions & 1 deletion tests/Doctrine/Tests/DBAL/Platforms/SQLAzurePlatformTest.php
Expand Up @@ -9,6 +9,9 @@
*/
class SQLAzurePlatformTest extends DbalTestCase
{
/**
* @var \Doctrine\DBAL\Platforms\SQLAzurePlatform
*/
private $platform;

protected function setUp()
Expand All @@ -26,4 +29,3 @@ public function testCreateFederatedOnTable()
self::assertEquals(array('CREATE TABLE tbl (id INT NOT NULL) FEDERATED ON (TblId = id)'), $this->platform->getCreateTableSQL($table));
}
}

Expand Up @@ -10,6 +10,9 @@
*/
class ExpressionBuilderTest extends \Doctrine\Tests\DbalTestCase
{
/**
* @var ExpressionBuilder
*/
protected $expr;

protected function setUp()
Expand Down
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DBAL/Query/QueryBuilderTest.php
Expand Up @@ -11,6 +11,9 @@
*/
class QueryBuilderTest extends \Doctrine\Tests\DbalTestCase
{
/**
* @var \Doctrine\DBAL\Connection
*/
protected $conn;

protected function setUp()
Expand Down
Expand Up @@ -8,7 +8,14 @@

abstract class AbstractTestCase extends \PHPUnit\Framework\TestCase
{
/**
* @var \Doctrine\DBAL\Connection
*/
protected $conn;

/**
* @var SQLAzureShardManager
*/
protected $sm;

protected function setUp()
Expand Down
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DBAL/Tools/Console/RunSqlCommandTest.php
Expand Up @@ -14,6 +14,9 @@ class RunSqlCommandTest extends \PHPUnit\Framework\TestCase
/** @var RunSqlCommand */
private $command;

/**
* @var \Doctrine\DBAL\Connection
*/
private $connectionMock;

protected function setUp()
Expand Down
13 changes: 10 additions & 3 deletions tests/Doctrine/Tests/DBAL/Types/ArrayTest.php
Expand Up @@ -2,14 +2,21 @@

namespace Doctrine\Tests\DBAL\Types;

use Doctrine\DBAL\Platforms\AbstractPlatform;
use Doctrine\DBAL\Types\Type;
use Doctrine\Tests\DBAL\Mocks\MockPlatform;

class ArrayTest extends \Doctrine\Tests\DbalTestCase
{
protected
$_platform,
$_type;
/**
* @var AbstractPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
12 changes: 9 additions & 3 deletions tests/Doctrine/Tests/DBAL/Types/BooleanTest.php
Expand Up @@ -7,9 +7,15 @@

class BooleanTest extends \Doctrine\Tests\DbalTestCase
{
protected
$_platform,
$_type;
/**
* @var MockPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
12 changes: 9 additions & 3 deletions tests/Doctrine/Tests/DBAL/Types/DecimalTest.php
Expand Up @@ -7,9 +7,15 @@

class DecimalTest extends \Doctrine\Tests\DbalTestCase
{
protected
$_platform,
$_type;
/**
* @var MockPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
10 changes: 9 additions & 1 deletion tests/Doctrine/Tests/DBAL/Types/FloatTest.php
Expand Up @@ -7,7 +7,15 @@

class FloatTest extends \Doctrine\Tests\DbalTestCase
{
protected $_platform, $_type;
/**
* @var MockPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
12 changes: 9 additions & 3 deletions tests/Doctrine/Tests/DBAL/Types/GuidTypeTest.php
Expand Up @@ -7,9 +7,15 @@

class GuidTest extends \Doctrine\Tests\DbalTestCase
{
protected
$_platform,
$_type;
/**
* @var MockPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
12 changes: 9 additions & 3 deletions tests/Doctrine/Tests/DBAL/Types/IntegerTest.php
Expand Up @@ -7,9 +7,15 @@

class IntegerTest extends \Doctrine\Tests\DbalTestCase
{
protected
$_platform,
$_type;
/**
* @var MockPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
12 changes: 9 additions & 3 deletions tests/Doctrine/Tests/DBAL/Types/ObjectTest.php
Expand Up @@ -7,9 +7,15 @@

class ObjectTest extends \Doctrine\Tests\DbalTestCase
{
protected
$_platform,
$_type;
/**
* @var MockPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
12 changes: 9 additions & 3 deletions tests/Doctrine/Tests/DBAL/Types/SmallIntTest.php
Expand Up @@ -7,9 +7,15 @@

class SmallIntTest extends \Doctrine\Tests\DbalTestCase
{
protected
$_platform,
$_type;
/**
* @var MockPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
12 changes: 9 additions & 3 deletions tests/Doctrine/Tests/DBAL/Types/StringTest.php
Expand Up @@ -7,9 +7,15 @@

class StringTest extends \Doctrine\Tests\DbalTestCase
{
protected
$_platform,
$_type;
/**
* @var MockPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
12 changes: 9 additions & 3 deletions tests/Doctrine/Tests/DBAL/Types/VarDateTimeTest.php
Expand Up @@ -7,9 +7,15 @@

class VarDateTimeTest extends \Doctrine\Tests\DbalTestCase
{
protected
$_platform,
$_type;
/**
* @var MockPlatform
*/
protected $_platform;

/**
* @var Type
*/
protected $_type;

protected function setUp()
{
Expand Down
3 changes: 3 additions & 0 deletions tests/Doctrine/Tests/DbalPerformanceTestListener.php
Expand Up @@ -9,6 +9,9 @@
*/
class DbalPerformanceTestListener extends \PHPUnit\Framework\BaseTestListener
{
/**
* @var string[][]
*/
private $timings = [];

/**
Expand Down

0 comments on commit ec85e54

Please sign in to comment.