Commit 0d76c6e9 authored by Tobias Schultze's avatar Tobias Schultze

setUp and tearDown are meant to be protected

parent bd9b9882
......@@ -39,7 +39,7 @@ class ConfigurationTest extends DbalTestCase
/**
* {@inheritdoc}
*/
public function setUp()
protected function setUp()
{
$this->config = new Configuration();
}
......
......@@ -24,7 +24,7 @@ class ConnectionTest extends \Doctrine\Tests\DbalTestCase
'port' => '1234'
);
public function setUp()
protected function setUp()
{
$this->_conn = \Doctrine\DBAL\DriverManager::getConnection($this->params);
}
......
......@@ -4,7 +4,7 @@ namespace Doctrine\Tests\DBAL;
class OCI8StatementTest extends \Doctrine\Tests\DbalTestCase
{
public function setUp()
protected function setUp()
{
if (!extension_loaded('oci8')) {
$this->markTestSkipped('oci8 is not installed.');
......
......@@ -10,7 +10,7 @@ use PDO;
*/
class BlobTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -8,13 +8,13 @@ use Doctrine\DBAL\Types\Type;
class ConnectionTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
public function setUp()
protected function setUp()
{
$this->resetSharedConn();
parent::setUp();
}
public function tearDown()
protected function tearDown()
{
parent::tearDown();
$this->resetSharedConn();
......
......@@ -11,7 +11,7 @@ class DataAccessTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
static private $generated = false;
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -3,7 +3,7 @@ namespace Doctrine\Tests\DBAL\Functional\Driver\Mysqli;
class ConnectionTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
public function setUp()
protected function setUp()
{
if (!extension_loaded('mysqli')) {
$this->markTestSkipped('mysqli is not installed.');
......@@ -16,7 +16,7 @@ class ConnectionTest extends \Doctrine\Tests\DbalFunctionalTestCase
}
}
public function tearDown()
protected function tearDown()
{
parent::tearDown();
}
......
......@@ -10,7 +10,7 @@ use Doctrine\Tests\DbalFunctionalTestCase;
*/
class MasterSlaveConnectionTest extends DbalFunctionalTestCase
{
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -6,7 +6,7 @@ class ModifyLimitQueryTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
private static $tableCreated = false;
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -101,7 +101,7 @@ class NamedParametersTest extends \Doctrine\Tests\DbalFunctionalTestCase
);
}
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -14,7 +14,7 @@ class PortabilityTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
private $portableConnection;
public function tearDown()
protected function tearDown()
{
if ($this->portableConnection) {
$this->portableConnection->close();
......
......@@ -12,7 +12,7 @@ class ResultCacheTest extends \Doctrine\Tests\DbalFunctionalTestCase
private $expectedResult = array(array('test_int' => 100, 'test_string' => 'foo'), array('test_int' => 200, 'test_string' => 'bar'), array('test_int' => 300, 'test_string' => 'baz'));
private $sqlLogger;
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -7,7 +7,7 @@ use Doctrine\Tests\TestUtil;
class OracleSchemaManagerTest extends SchemaManagerFunctionalTestCase
{
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -9,7 +9,7 @@ use Doctrine\DBAL\Types\Type;
class PostgreSqlSchemaManagerTest extends SchemaManagerFunctionalTestCase
{
public function tearDown()
protected function tearDown()
{
parent::tearDown();
......
......@@ -11,7 +11,7 @@ class TableGeneratorTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
private $generator;
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -7,7 +7,7 @@ use Doctrine\DBAL\Types\Type;
class TemporaryTableTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
public function setUp()
protected function setUp()
{
parent::setUp();
try {
......@@ -17,7 +17,7 @@ class TemporaryTableTest extends \Doctrine\Tests\DbalFunctionalTestCase
}
}
public function tearDown()
protected function tearDown()
{
if ($this->_conn) {
try {
......
......@@ -10,7 +10,7 @@ use Doctrine\DBAL\Schema\Table;
*/
class DBAL510Test extends \Doctrine\Tests\DbalFunctionalTestCase
{
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -8,7 +8,7 @@ class TypeConversionTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
static private $typeCounter = 0;
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -6,7 +6,7 @@ use PDO;
class WriteTest extends \Doctrine\Tests\DbalFunctionalTestCase
{
public function setUp()
protected function setUp()
{
parent::setUp();
......
......@@ -4,12 +4,12 @@ namespace Doctrine\Tests\DBAL\Logging;
class DebugStackTest extends \Doctrine\Tests\DbalTestCase
{
public function setUp()
protected function setUp()
{
$this->logger = new \Doctrine\DBAL\Logging\DebugStack();
}
public function tearDown()
protected function tearDown()
{
unset($this->logger);
}
......
......@@ -23,7 +23,7 @@ abstract class AbstractPlatformTestCase extends \Doctrine\Tests\DbalTestCase
abstract public function createPlatform();
public function setUp()
protected function setUp()
{
$this->_platform = $this->createPlatform();
}
......
......@@ -12,7 +12,7 @@ class ReservedKeywordsValidatorTest extends \Doctrine\Tests\DbalTestCase
*/
private $validator;
public function setUp()
protected function setUp()
{
$this->validator = new ReservedKeywordsValidator(array(
new \Doctrine\DBAL\Platforms\Keywords\MySQLKeywords()
......
......@@ -11,7 +11,7 @@ class SQLAzurePlatformTest extends DbalTestCase
{
private $platform;
public function setUp()
protected function setUp()
{
$this->platform = new \Doctrine\DBAL\Platforms\SQLAzurePlatform();
}
......
......@@ -25,7 +25,7 @@ class StatementTest extends \Doctrine\Tests\DbalTestCase
/**
* {@inheritdoc}
*/
public function setUp()
protected function setUp()
{
$this->wrappedStmt = $this->createWrappedStatement();
$this->conn = $this->createConnection();
......
......@@ -12,7 +12,7 @@ class ExpressionBuilderTest extends \Doctrine\Tests\DbalTestCase
{
protected $expr;
public function setUp()
protected function setUp()
{
$conn = $this->getMock('Doctrine\DBAL\Connection', array(), array(), '', false);
......
......@@ -12,7 +12,7 @@ class QueryBuilderTest extends \Doctrine\Tests\DbalTestCase
{
protected $conn;
public function setUp()
protected function setUp()
{
$this->conn = $this->getMock('Doctrine\DBAL\Connection', array(), array(), '', false);
......
......@@ -14,7 +14,7 @@ class MySqlSchemaManagerTest extends \PHPUnit_Framework_TestCase
*/
private $manager;
public function setUp()
protected function setUp()
{
$eventManager = new EventManager();
$driverMock = $this->getMock('Doctrine\DBAL\Driver');
......
......@@ -16,7 +16,7 @@ class MySQLSchemaTest extends \PHPUnit_Framework_TestCase
*/
private $platform;
public function setUp()
protected function setUp()
{
$this->comparator = new \Doctrine\DBAL\Schema\Comparator;
$this->platform = new \Doctrine\DBAL\Platforms\MySqlPlatform;
......
......@@ -28,7 +28,7 @@ class SingleDatabaseSynchronizerTest extends \PHPUnit_Framework_TestCase
private $conn;
private $synchronizer;
public function setUp()
protected function setUp()
{
$this->conn = DriverManager::getConnection(array(
'driver' => 'pdo_sqlite',
......
......@@ -11,7 +11,7 @@ abstract class AbstractTestCase extends \PHPUnit_Framework_TestCase
protected $conn;
protected $sm;
public function setUp()
protected function setUp()
{
if (!isset($GLOBALS['db_type']) || strpos($GLOBALS['db_type'], "sqlsrv") === false) {
$this->markTestSkipped('No driver or sqlserver driver specified.');
......
......@@ -23,7 +23,7 @@ class StatementTest extends \Doctrine\Tests\DbalTestCase
*/
private $pdoStatement;
public function setUp()
protected function setUp()
{
$this->pdoStatement = $this->getMock('\PDOStatement', array('execute', 'bindParam', 'bindValue'));
$platform = new \Doctrine\Tests\DBAL\Mocks\MockPlatform();
......
......@@ -17,7 +17,7 @@ class ArrayTest extends \Doctrine\Tests\DbalTestCase
$this->_type = Type::getType('array');
}
public function tearDown()
protected function tearDown()
{
error_reporting(-1); // reactive all error levels
}
......
......@@ -17,7 +17,7 @@ class ObjectTest extends \Doctrine\Tests\DbalTestCase
$this->_type = Type::getType('object');
}
public function tearDown()
protected function tearDown()
{
error_reporting(-1); // reactive all error levels
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment