aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorbrunoais <brunoaiss@gmail.com>2015-10-25 17:22:40 +0000
committerbrunoais <brunoaiss@gmail.com>2015-11-11 08:38:38 +0000
commit062352e312402820fd081a702c599a10c610e888 (patch)
tree6ab299b1eaf409974b23ee61049775ad039c748d /tests
parentbb260f02e0de549f0ac2327b1d7b4f4a236a9a2a (diff)
downloadforums-062352e312402820fd081a702c599a10c610e888.tar
forums-062352e312402820fd081a702c599a10c610e888.tar.gz
forums-062352e312402820fd081a702c599a10c610e888.tar.bz2
forums-062352e312402820fd081a702c599a10c610e888.tar.xz
forums-062352e312402820fd081a702c599a10c610e888.zip
[feature/sql-bool-builder] Changing syntax pt2. Fix tests
PHPBB3-13652
Diffstat (limited to 'tests')
-rw-r--r--tests/dbal/boolean_processor_test.php58
1 files changed, 38 insertions, 20 deletions
diff --git a/tests/dbal/boolean_processor_test.php b/tests/dbal/boolean_processor_test.php
index 8662485ac8..226f5307b2 100644
--- a/tests/dbal/boolean_processor_test.php
+++ b/tests/dbal/boolean_processor_test.php
@@ -162,17 +162,25 @@ class phpbb_boolean_processor_test extends phpbb_database_test_case
),
),
'WHERE' => array('AND',
- array('OR',
- array('AND',
- array('ug.user_id', 'IN', array(1, 2, 3, 4)),
- array('ug.group_id', '=', 2),
- ),
- array('AND',
- array('ug.group_id', '=', 1),
- array('b.ban_id', 'IS_NOT', NULL),
+ array(
+ array('OR',
+ array(
+ array('AND',
+ array(
+ array('ug.user_id', 'IN', array(1, 2, 3, 4)),
+ array('ug.group_id', '=', 2),
+ ),
+ ),
+ array('AND',
+ array(
+ array('ug.group_id', '=', 1),
+ array('b.ban_id', 'IS_NOT', NULL),
+ ),
+ ),
+ ),
),
+ array('u.user_id', '=', 'ug.user_id'),
),
- array('u.user_id', '=', 'ug.user_id'),
),
'ORDER_BY' => 'u.user_id',
);
@@ -204,9 +212,11 @@ class phpbb_boolean_processor_test extends phpbb_database_test_case
'phpbb_user_group' => 'ug',
),
'WHERE' => array('AND',
- array('ug.user_id', 'IN', array(1, 2, 3, 4)),
- array('ug.group_id', '=', 1),
- array('u.user_id', '=', 'ug.user_id'),
+ array(
+ array('ug.user_id', 'IN', array(1, 2, 3, 4)),
+ array('ug.group_id', '=', 1),
+ array('u.user_id', '=', 'ug.user_id'),
+ ),
),
'ORDER_BY' => 'u.user_id',
);
@@ -240,13 +250,19 @@ class phpbb_boolean_processor_test extends phpbb_database_test_case
'phpbb_user_group' => 'ug',
),
'WHERE' => array('AND',
- array('NOT',
- array('OR',
- array('ug.group_id', '=', 1),
- array('ug.group_id', '=', 2),
+ array(
+ array('NOT',
+ array(
+ array('OR',
+ array(
+ array('ug.group_id', '=', 1),
+ array('ug.group_id', '=', 2),
+ ),
+ ),
+ ),
),
+ array('u.user_id', '=', 'ug.user_id'),
),
- array('u.user_id', '=', 'ug.user_id'),
),
'ORDER_BY' => 'u.user_id',
);
@@ -283,9 +299,11 @@ class phpbb_boolean_processor_test extends phpbb_database_test_case
),
),
'WHERE' => array('AND',
- array('ug.group_id', '=', 1),
- array('u.user_id', '=', 'ug.user_id'),
- array('b.ban_id', 'IS', NULL),
+ array(
+ array('ug.group_id', '=', 1),
+ array('u.user_id', '=', 'ug.user_id'),
+ array('b.ban_id', 'IS', NULL),
+ ),
),
'ORDER_BY' => 'u.username',
);