diff options
author | Joas Schilling <nickvergessen@gmx.de> | 2013-03-25 15:34:18 +0100 |
---|---|---|
committer | Joas Schilling <nickvergessen@gmx.de> | 2013-03-25 15:34:18 +0100 |
commit | 053c75543de4c8e5d787a2e344b837f867842f8d (patch) | |
tree | 0c2647f82a6316f5c8adba37dcdd717b8610571c /tests/notification | |
parent | 060876e627db127c72a953d37e83f5176a085e5d (diff) | |
download | forums-053c75543de4c8e5d787a2e344b837f867842f8d.tar forums-053c75543de4c8e5d787a2e344b837f867842f8d.tar.gz forums-053c75543de4c8e5d787a2e344b837f867842f8d.tar.bz2 forums-053c75543de4c8e5d787a2e344b837f867842f8d.tar.xz forums-053c75543de4c8e5d787a2e344b837f867842f8d.zip |
[ticket/11405] Correctly prefill the tables (missed the posts and not-types)
PHPBB3-11405
Diffstat (limited to 'tests/notification')
-rw-r--r-- | tests/notification/fixtures/submit_post_notification.xml | 34 | ||||
-rw-r--r-- | tests/notification/submit_post_type_post_test.php | 6 | ||||
-rw-r--r-- | tests/notification/submit_post_type_quote_test.php | 4 |
3 files changed, 39 insertions, 5 deletions
diff --git a/tests/notification/fixtures/submit_post_notification.xml b/tests/notification/fixtures/submit_post_notification.xml index 5c59edf073..51dd2f8dbd 100644 --- a/tests/notification/fixtures/submit_post_notification.xml +++ b/tests/notification/fixtures/submit_post_notification.xml @@ -25,12 +25,14 @@ <column>user_id</column> <column>item_id</column> <column>item_parent_id</column> + <column>notification_read</column> <column>notification_data</column> <row> <value>post</value> <value>5</value> <value>1</value> <value>1</value> + <value>0</value> <value></value> </row> <row> @@ -38,6 +40,7 @@ <value>5</value> <value>1</value> <value>1</value> + <value>0</value> <value></value> </row> <row> @@ -45,10 +48,41 @@ <value>8</value> <value>1</value> <value>1</value> + <value>0</value> <value></value> </row> </table> + <table name="phpbb_notification_types"> + <column>notification_type</column> + <column>notification_type_enabled</column> + <row> + <value>post</value> + <value>1</value> + </row> + <row> + <value>quote</value> + <value>1</value> + </row> + </table> <table name="phpbb_posts"> + <column>post_id</column> + <column>topic_id</column> + <column>forum_id</column> + <column>post_text</column> + <row> + <value>1</value> + <value>1</value> + <value>1</value> + <value></value> + </row> + </table> + <table name="phpbb_topics"> + <column>topic_id</column> + <column>forum_id</column> + <row> + <value>1</value> + <value>1</value> + </row> </table> <table name="phpbb_topics_watch"> <column>topic_id</column> diff --git a/tests/notification/submit_post_type_post_test.php b/tests/notification/submit_post_type_post_test.php index 2e269ff080..f439c49167 100644 --- a/tests/notification/submit_post_type_post_test.php +++ b/tests/notification/submit_post_type_post_test.php @@ -92,10 +92,10 @@ class phpbb_notification_submit_post_type_post_test extends phpbb_notification_s ORDER BY user_id ASC, item_id ASC"; $result = $this->db->sql_query($sql); $this->assertEquals(array( - array('user_id' => 3, 'item_id' => 1, 'item_parent_id' => 1), + array('user_id' => 3, 'item_id' => 2, 'item_parent_id' => 1), array('user_id' => 5, 'item_id' => 1, 'item_parent_id' => 1), - array('user_id' => 6, 'item_id' => 1, 'item_parent_id' => 1), - array('user_id' => 7, 'item_id' => 1, 'item_parent_id' => 1), + array('user_id' => 6, 'item_id' => 2, 'item_parent_id' => 1), + array('user_id' => 7, 'item_id' => 2, 'item_parent_id' => 1), array('user_id' => 8, 'item_id' => 1, 'item_parent_id' => 1), ), $this->db->sql_fetchrowset($result)); $this->db->sql_freeresult($result); diff --git a/tests/notification/submit_post_type_quote_test.php b/tests/notification/submit_post_type_quote_test.php index 603f7b2020..9b2323f770 100644 --- a/tests/notification/submit_post_type_quote_test.php +++ b/tests/notification/submit_post_type_quote_test.php @@ -98,9 +98,9 @@ class phpbb_notification_submit_post_type_quote_test extends phpbb_notification_ ORDER BY user_id ASC, item_id ASC"; $result = $this->db->sql_query($sql); $this->assertEquals(array( - array('user_id' => 3, 'item_id' => 1, 'item_parent_id' => 1), + array('user_id' => 3, 'item_id' => 2, 'item_parent_id' => 1), array('user_id' => 5, 'item_id' => 1, 'item_parent_id' => 1), - array('user_id' => 7, 'item_id' => 1, 'item_parent_id' => 1), + array('user_id' => 7, 'item_id' => 2, 'item_parent_id' => 1), ), $this->db->sql_fetchrowset($result)); $this->db->sql_freeresult($result); } |