[ticket/11474] Add test user with only global m_approve permissions

PHPBB3-11405
PHPBB3-11474
This commit is contained in:
Joas Schilling 2013-03-27 11:12:33 +01:00
parent d8a63047aa
commit bdd2062a66
2 changed files with 22 additions and 2 deletions

View file

@ -107,6 +107,14 @@
<value></value> <value></value>
<value></value> <value></value>
</row> </row>
<row>
<value>9</value>
<value>test glboal-permissions</value>
<value></value>
<value></value>
<value></value>
<value></value>
</row>
</table> </table>
<table name="phpbb_user_notifications"> <table name="phpbb_user_notifications">
<column>item_type</column> <column>item_type</column>
@ -156,5 +164,12 @@
<value></value> <value></value>
<value>0</value> <value>0</value>
</row> </row>
<row>
<value>needs_approval</value>
<value>0</value>
<value>9</value>
<value></value>
<value>1</value>
</row>
</table> </table>
</dataset> </dataset>

View file

@ -31,18 +31,21 @@ class phpbb_notification_submit_post_type_post_in_queue_test extends phpbb_notif
'm_approve', 'm_approve',
array(1, 0), array(1, 0),
array( array(
0 => array(
'm_approve' => array(9),
),
1 => array( 1 => array(
'm_approve' => array(3, 4, 6, 7, 8), 'm_approve' => array(3, 4, 6, 7, 8),
), ),
), ),
), ),
array( array(
array(3, 4, 6, 7, 8), array(3, 4, 6, 7, 8, 9),
'f_read', 'f_read',
1, 1,
array( array(
1 => array( 1 => array(
'f_read' => array(3, 6, 7, 8), 'f_read' => array(3, 6, 7, 8, 9),
), ),
), ),
), ),
@ -84,6 +87,7 @@ class phpbb_notification_submit_post_type_post_in_queue_test extends phpbb_notif
* 6 => Moderator, but already notified, should STILL receive a new notification * 6 => Moderator, but already notified, should STILL receive a new notification
* 7 => Moderator, but option disabled, should NOT receive a notification * 7 => Moderator, but option disabled, should NOT receive a notification
* 8 => Moderator, option set to default, should receive a notification * 8 => Moderator, option set to default, should receive a notification
* 9 => Moderator, has only global mod permissions, should receive a notification
*/ */
array( array(
array('force_approved_state' => false), array('force_approved_state' => false),
@ -95,6 +99,7 @@ class phpbb_notification_submit_post_type_post_in_queue_test extends phpbb_notif
array('user_id' => 6, 'item_id' => 1, 'item_parent_id' => 1), array('user_id' => 6, 'item_id' => 1, 'item_parent_id' => 1),
array('user_id' => 6, 'item_id' => 2, 'item_parent_id' => 1), array('user_id' => 6, 'item_id' => 2, 'item_parent_id' => 1),
array('user_id' => 8, 'item_id' => 2, 'item_parent_id' => 1), array('user_id' => 8, 'item_id' => 2, 'item_parent_id' => 1),
array('user_id' => 9, 'item_id' => 2, 'item_parent_id' => 1),
), ),
), ),
); );