aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/repair
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@owncloud.com>2015-07-06 12:34:19 +0200
committerJoas Schilling <nickvergessen@owncloud.com>2015-07-21 15:25:47 +0200
commitde348180ae257017a9a2af05dac72286bf262bed (patch)
tree3fe07523249ca6a6e91defcff781b86be031b98c /tests/lib/repair
parent1bfb944d515c88f915739c3b920d39d6da200d29 (diff)
downloadnextcloud-server-de348180ae257017a9a2af05dac72286bf262bed.tar.gz
nextcloud-server-de348180ae257017a9a2af05dac72286bf262bed.zip
Use the public interface and our method instead of the doctrine thing
Diffstat (limited to 'tests/lib/repair')
-rw-r--r--tests/lib/repair/cleantags.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/lib/repair/cleantags.php b/tests/lib/repair/cleantags.php
index b455aa870fb..fc9b21d4636 100644
--- a/tests/lib/repair/cleantags.php
+++ b/tests/lib/repair/cleantags.php
@@ -18,7 +18,7 @@ class CleanTags extends \Test\TestCase {
/** @var \OC\RepairStep */
protected $repair;
- /** @var \Doctrine\DBAL\Connection */
+ /** @var \OCP\IDBConnection */
protected $connection;
/** @var int */
@@ -39,7 +39,7 @@ class CleanTags extends \Test\TestCase {
}
protected function cleanUpTables() {
- $qb = $this->connection->createQueryBuilder();
+ $qb = $this->connection->getQueryBuilder();
$qb->delete('`*PREFIX*vcategory`')
->execute();
@@ -83,7 +83,7 @@ class CleanTags extends \Test\TestCase {
* @param string $message
*/
protected function assertEntryCount($tableName, $expected, $message = '') {
- $qb = $this->connection->createQueryBuilder();
+ $qb = $this->connection->getQueryBuilder();
$result = $qb->select('COUNT(*)')
->from('`' . $tableName . '`')
->execute();
@@ -99,7 +99,7 @@ class CleanTags extends \Test\TestCase {
* @return int
*/
protected function addTagCategory($category, $type) {
- $qb = $this->connection->createQueryBuilder();
+ $qb = $this->connection->getQueryBuilder();
$qb->insert('`*PREFIX*vcategory`')
->values([
'`uid`' => $qb->createNamedParameter('TestRepairCleanTags'),
@@ -118,7 +118,7 @@ class CleanTags extends \Test\TestCase {
* @param string $type
*/
protected function addTagEntry($objectId, $category, $type) {
- $qb = $this->connection->createQueryBuilder();
+ $qb = $this->connection->getQueryBuilder();
$qb->insert('`*PREFIX*vcategory_to_object`')
->values([
'`objid`' => $qb->createNamedParameter($objectId, \PDO::PARAM_INT),
@@ -137,7 +137,7 @@ class CleanTags extends \Test\TestCase {
return $this->createdFile;
}
- $qb = $this->connection->createQueryBuilder();
+ $qb = $this->connection->getQueryBuilder();
// We create a new file entry and delete it after the test again
$fileName = $this->getUniqueID('TestRepairCleanTags', 12);
@@ -174,7 +174,7 @@ class CleanTags extends \Test\TestCase {
// FIXME INSTEAD HELP FIXING DOCTRINE
// FIXME https://github.com/owncloud/core/issues/13303
// FIXME ALSO FIX https://github.com/owncloud/core/commit/2dd85ec984c12d3be401518f22c90d2327bec07a
- $qb = $this->connection->createQueryBuilder();
+ $qb = $this->connection->getQueryBuilder();
$result = $qb->select("MAX($idName)")
->from($tableName)
->execute();