diff options
author | Morris Jobke <hey@morrisjobke.de> | 2018-06-19 14:12:22 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-06-19 14:12:22 +0200 |
commit | 8646f01320f685de1a428b6e696c7ea691defffc (patch) | |
tree | 0d1e951f9102b9d32c5a9bdd571d7a4da604e471 /tests | |
parent | 1d65e44dae971d85c785d74ed7f9b4a574d54121 (diff) | |
parent | 4187d2cdb391bbe7518c602a579abd1305787bf2 (diff) | |
download | nextcloud-server-8646f01320f685de1a428b6e696c7ea691defffc.tar.gz nextcloud-server-8646f01320f685de1a428b6e696c7ea691defffc.zip |
Merge pull request #9881 from nextcloud/user-db-backend-querybuilder
use query builder in all places in the db user backend
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lib/DB/QueryBuilder/FunctionBuilderTest.php | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/lib/DB/QueryBuilder/FunctionBuilderTest.php b/tests/lib/DB/QueryBuilder/FunctionBuilderTest.php index 1b998287c98..136650741f5 100644 --- a/tests/lib/DB/QueryBuilder/FunctionBuilderTest.php +++ b/tests/lib/DB/QueryBuilder/FunctionBuilderTest.php @@ -110,4 +110,14 @@ class FunctionBuilderTest extends TestCase { $this->assertEquals(1, $query->execute()->fetchColumn()); } + + public function testCount() { + $query = $this->connection->getQueryBuilder(); + + $query->select($query->func()->count('appid')); + $query->from('appconfig') + ->setMaxResults(1); + + $this->assertGreaterThan(1, $query->execute()->fetchColumn()); + } } |