aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIgor Wiedler <igor@wiedler.ch>2012-03-23 11:43:54 +0100
committerIgor Wiedler <igor@wiedler.ch>2012-03-23 11:43:54 +0100
commite35aecb9bd051b46a804366cf461d426dc062404 (patch)
tree368f0e9b4870ba7e41dac2c21d304e64f595d03e
parentbaefbdb8825a37051a200203a0191d34caa12229 (diff)
parentcc13bac412442a1d72affcc3222b6bfca094e92a (diff)
downloadforums-e35aecb9bd051b46a804366cf461d426dc062404.tar
forums-e35aecb9bd051b46a804366cf461d426dc062404.tar.gz
forums-e35aecb9bd051b46a804366cf461d426dc062404.tar.bz2
forums-e35aecb9bd051b46a804366cf461d426dc062404.tar.xz
forums-e35aecb9bd051b46a804366cf461d426dc062404.zip
Merge remote-tracking branch 'upstream/develop' into feature/event-dispatcher
* upstream/develop: (30 commits) [task/travis] Refactor php version check for dbunit install [task/travis] Exclude functional and slow tests [ticket/10719] Revert "Skip functional tests on PHP 5.2" [task/travis-develop2] Update version from 5.3 to 5.3.2 [task/travis] Dropping support for 5.2 in develop branch [task/travis] Some more small travis fixes [task/travis] Rename travis phpunit config files [task/travis] Fixing some travis issues [ticket/10684] Adjust function and parameter name, minor changes. [task/travis] Add automated testing to readme [task/travis] Removing development information [task/travis] Adding Travis Continuous Intergration Support [ticket/10704] minor typo in a comment [ticket/10717] Fix profile field sample in prosilverĀ“s memberlist_view.html [ticket/10691] Fixed the speed of creating search index [task/php54-ascraeus] Bring p_master#module_auth into PHP 5 era. [task/php54] Disable E_STRICT in Olympus when running on PHP 5.4. [task/php54] Refactor error_reporting call slightly. [ticket/10690] Fix undefined UNAPPROVED_POSTS_ZERO_TOTAL in queue [ticket/10689] Fix "First character"-option in "Find a member"-search ...
-rw-r--r--.travis.yml25
-rw-r--r--README.md6
-rw-r--r--phpBB/develop/create_search_index.php2
-rw-r--r--phpBB/includes/acp/acp_users.php2
-rw-r--r--phpBB/includes/functions_module.php24
-rw-r--r--phpBB/includes/functions_posting.php46
-rw-r--r--phpBB/includes/functions_privmsgs.php17
-rw-r--r--phpBB/includes/functions_user.php33
-rw-r--r--phpBB/includes/mcp/mcp_topic.php11
-rw-r--r--phpBB/includes/startup.php3
-rw-r--r--phpBB/language/en/mcp.php1
-rw-r--r--phpBB/memberlist.php1
-rw-r--r--phpBB/styles/prosilver/template/mcp_queue.html2
-rw-r--r--phpBB/styles/prosilver/template/mcp_topic.html1
-rw-r--r--phpBB/styles/prosilver/template/memberlist_view.html2
-rw-r--r--phpBB/styles/subsilver2/template/mcp_queue.html2
-rw-r--r--phpBB/styles/subsilver2/template/mcp_topic.html1
-rw-r--r--phpunit.xml.all4
-rw-r--r--phpunit.xml.dist4
-rw-r--r--phpunit.xml.functional4
-rw-r--r--tests/bootstrap.php6
-rw-r--r--travis/phpunit-mysql-travis.xml34
-rw-r--r--travis/phpunit-postgres-travis.xml36
23 files changed, 201 insertions, 66 deletions
diff --git a/.travis.yml b/.travis.yml
new file mode 100644
index 0000000000..d5e1231584
--- /dev/null
+++ b/.travis.yml
@@ -0,0 +1,25 @@
+language: php
+php:
+ - 5.3.2
+ - 5.4
+
+env:
+ - DB=mysql
+ - DB=postgres
+
+before_script:
+ - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'DROP DATABASE IF EXISTS phpbb_tests;' -U postgres; fi"
+ - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'create database phpbb_tests;' -U postgres; fi"
+ - sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'create database IF NOT EXISTS phpbb_tests;'; fi"
+ - sh -c "if [ '$TRAVIS_PHP_VERSION' = '5.2' ]; then pear install --force phpunit/DbUnit; else pyrus install --force phpunit/DbUnit; fi"
+ - phpenv rehash
+
+script:
+ - phpunit --configuration travis/phpunit-$DB-travis.xml
+
+notifications:
+ email:
+ recipients:
+ - dev-team@phpbb.com
+ on_success: change
+ on_failure: change
diff --git a/README.md b/README.md
index 6b94f898a3..51e65176c6 100644
--- a/README.md
+++ b/README.md
@@ -15,6 +15,12 @@ Find support and lots more on [phpBB.com](http://www.phpbb.com)! Discuss the dev
3. [Read our Git Contribution Guidelines](http://wiki.phpbb.com/Git); if you're new to git, also read [the introduction guide](http://wiki.phpbb.com/display/DEV/Working+with+Git)
4. Send us a pull request
+## AUTOMATED TESTING
+
+We have unit and functional tests in order to prevent regressions. You can view the bamboo continuous integration [here](http://bamboo.phpbb.com) or check our travis build below.
+develop - [![Build Status](https://secure.travis-ci.org/phpbb/phpbb3.png?branch=develop)](http://travis-ci.org/phpbb/phpbb3)
+develop-olympus - [![Build Status](https://secure.travis-ci.org/phpbb/phpbb3.png?branch=develop-olympus)](http://travis-ci.org/phpbb/phpbb3)
+
## LICENSE
[GNU General Public License v2](http://opensource.org/licenses/gpl-2.0.php)
diff --git a/phpBB/develop/create_search_index.php b/phpBB/develop/create_search_index.php
index 1de20f3099..f329b805a0 100644
--- a/phpBB/develop/create_search_index.php
+++ b/phpBB/develop/create_search_index.php
@@ -35,7 +35,6 @@ $search_errors = array();
$search = new $class_name($search_errors);
$batch_size = isset($argv[2]) ? $argv[2] : 2000;
-$time = time();
if (method_exists($search, 'create_index'))
{
@@ -67,6 +66,7 @@ else
while ($post_counter <= $max_post_id)
{
$row_count = 0;
+ $time = time();
printf("Processing posts with %d <= post_id <= %d\n",
$post_counter + 1,
diff --git a/phpBB/includes/acp/acp_users.php b/phpBB/includes/acp/acp_users.php
index 97f4b1b5fd..cf6716c322 100644
--- a/phpBB/includes/acp/acp_users.php
+++ b/phpBB/includes/acp/acp_users.php
@@ -128,7 +128,7 @@ class acp_users
$dropdown_modes = array();
while ($row = $db->sql_fetchrow($result))
{
- if (!$this->p_master->module_auth($row['module_auth']))
+ if (!$this->p_master->module_auth_self($row['module_auth']))
{
continue;
}
diff --git a/phpBB/includes/functions_module.php b/phpBB/includes/functions_module.php
index db7defdc48..ad76be9f2f 100644
--- a/phpBB/includes/functions_module.php
+++ b/phpBB/includes/functions_module.php
@@ -128,7 +128,7 @@ class p_master
foreach ($this->module_cache['modules'] as $key => $row)
{
// Not allowed to view module?
- if (!$this->module_auth($row['module_auth']))
+ if (!$this->module_auth_self($row['module_auth']))
{
unset($this->module_cache['modules'][$key]);
continue;
@@ -315,9 +315,23 @@ class p_master
}
/**
- * Check module authorisation
+ * Check module authorisation.
+ *
+ * This is a non-static version that uses $this->acl_forum_id
+ * for the forum id.
+ */
+ function module_auth_self($module_auth)
+ {
+ return self::module_auth($module_auth, $this->acl_forum_id);
+ }
+
+ /**
+ * Check module authorisation.
+ *
+ * This is a static version, it must be given $forum_id.
+ * See also module_auth_self.
*/
- function module_auth($module_auth, $forum_id = false)
+ static function module_auth($module_auth, $forum_id)
{
global $auth, $config;
global $request;
@@ -362,11 +376,9 @@ class p_master
$module_auth = implode(' ', $tokens);
- // Make sure $id seperation is working fine
+ // Make sure $id separation is working fine
$module_auth = str_replace(' , ', ',', $module_auth);
- $forum_id = ($forum_id === false) ? $this->acl_forum_id : $forum_id;
-
$is_auth = false;
eval('$is_auth = (int) (' . preg_replace(array('#acl_([a-z0-9_]+)(,\$id)?#', '#\$id#', '#aclf_([a-z0-9_]+)#', '#cfg_([a-z0-9_]+)#', '#request_([a-zA-Z0-9_]+)#'), array('(int) $auth->acl_get(\'\\1\'\\2)', '(int) $forum_id', '(int) $auth->acl_getf_global(\'\\1\')', '(int) $config[\'\\1\']', '$request->variable(\'\\1\', false)'), $module_auth) . ');');
diff --git a/phpBB/includes/functions_posting.php b/phpBB/includes/functions_posting.php
index 4e4ce5bca7..b3816baedd 100644
--- a/phpBB/includes/functions_posting.php
+++ b/phpBB/includes/functions_posting.php
@@ -1180,36 +1180,32 @@ function user_notification($mode, $subject, $topic_title, $forum_name, $forum_id
$topic_title = ($topic_notification) ? $topic_title : $subject;
$topic_title = censor_text($topic_title);
- // Get banned User ID's
- $sql = 'SELECT ban_userid
- FROM ' . BANLIST_TABLE . '
- WHERE ban_userid <> 0
- AND ban_exclude <> 1';
- $result = $db->sql_query($sql);
-
- $sql_ignore_users = ANONYMOUS . ', ' . $user->data['user_id'];
- while ($row = $db->sql_fetchrow($result))
+ // Exclude guests, current user and banned users from notifications
+ if (!function_exists('phpbb_get_banned_user_ids'))
{
- $sql_ignore_users .= ', ' . (int) $row['ban_userid'];
+ include($phpbb_root_path . 'includes/functions_user.' . $phpEx);
}
- $db->sql_freeresult($result);
+ $sql_ignore_users = phpbb_get_banned_user_ids();
+ $sql_ignore_users[ANONYMOUS] = ANONYMOUS;
+ $sql_ignore_users[$user->data['user_id']] = $user->data['user_id'];
$notify_rows = array();
// -- get forum_userids || topic_userids
$sql = 'SELECT u.user_id, u.username, u.user_email, u.user_lang, u.user_notify_type, u.user_jabber
FROM ' . (($topic_notification) ? TOPICS_WATCH_TABLE : FORUMS_WATCH_TABLE) . ' w, ' . USERS_TABLE . ' u
- WHERE w.' . (($topic_notification) ? 'topic_id' : 'forum_id') . ' = ' . (($topic_notification) ? $topic_id : $forum_id) . "
- AND w.user_id NOT IN ($sql_ignore_users)
- AND w.notify_status = " . NOTIFY_YES . '
+ WHERE w.' . (($topic_notification) ? 'topic_id' : 'forum_id') . ' = ' . (($topic_notification) ? $topic_id : $forum_id) . '
+ AND ' . $db->sql_in_set('w.user_id', $sql_ignore_users, true) . '
+ AND w.notify_status = ' . NOTIFY_YES . '
AND u.user_type IN (' . USER_NORMAL . ', ' . USER_FOUNDER . ')
AND u.user_id = w.user_id';
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result))
{
- $notify_rows[$row['user_id']] = array(
- 'user_id' => $row['user_id'],
+ $notify_user_id = (int) $row['user_id'];
+ $notify_rows[$notify_user_id] = array(
+ 'user_id' => $notify_user_id,
'username' => $row['username'],
'user_email' => $row['user_email'],
'user_jabber' => $row['user_jabber'],
@@ -1219,30 +1215,29 @@ function user_notification($mode, $subject, $topic_title, $forum_name, $forum_id
'method' => $row['user_notify_type'],
'allowed' => false
);
+
+ // Add users who have been already notified to ignore list
+ $sql_ignore_users[$notify_user_id] = $notify_user_id;
}
$db->sql_freeresult($result);
// forum notification is sent to those not already receiving topic notifications
if ($topic_notification)
{
- if (sizeof($notify_rows))
- {
- $sql_ignore_users .= ', ' . implode(', ', array_keys($notify_rows));
- }
-
$sql = 'SELECT u.user_id, u.username, u.user_email, u.user_lang, u.user_notify_type, u.user_jabber
FROM ' . FORUMS_WATCH_TABLE . ' fw, ' . USERS_TABLE . " u
WHERE fw.forum_id = $forum_id
- AND fw.user_id NOT IN ($sql_ignore_users)
- AND fw.notify_status = " . NOTIFY_YES . '
+ AND " . $db->sql_in_set('fw.user_id', $sql_ignore_users, true) . '
+ AND fw.notify_status = ' . NOTIFY_YES . '
AND u.user_type IN (' . USER_NORMAL . ', ' . USER_FOUNDER . ')
AND u.user_id = fw.user_id';
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result))
{
- $notify_rows[$row['user_id']] = array(
- 'user_id' => $row['user_id'],
+ $notify_user_id = (int) $row['user_id'];
+ $notify_rows[$notify_user_id] = array(
+ 'user_id' => $notify_user_id,
'username' => $row['username'],
'user_email' => $row['user_email'],
'user_jabber' => $row['user_jabber'],
@@ -1273,7 +1268,6 @@ function user_notification($mode, $subject, $topic_title, $forum_name, $forum_id
}
}
-
// Now, we have to do a little step before really sending, we need to distinguish our users a little bit. ;)
$msg_users = $delete_ids = $update_notification = array();
foreach ($notify_rows as $user_id => $row)
diff --git a/phpBB/includes/functions_privmsgs.php b/phpBB/includes/functions_privmsgs.php
index 91e453b8e0..a6fb87536a 100644
--- a/phpBB/includes/functions_privmsgs.php
+++ b/phpBB/includes/functions_privmsgs.php
@@ -1666,6 +1666,7 @@ function pm_notification($mode, $author, $recipients, $subject, $message, $msg_i
$subject = censor_text($subject);
+ // Exclude guests, current user and banned users from notifications
unset($recipients[ANONYMOUS], $recipients[$user->data['user_id']]);
if (!sizeof($recipients))
@@ -1673,18 +1674,12 @@ function pm_notification($mode, $author, $recipients, $subject, $message, $msg_i
return;
}
- // Get banned User ID's
- $sql = 'SELECT ban_userid
- FROM ' . BANLIST_TABLE . '
- WHERE ' . $db->sql_in_set('ban_userid', array_map('intval', array_keys($recipients))) . '
- AND ban_exclude = 0';
- $result = $db->sql_query($sql);
-
- while ($row = $db->sql_fetchrow($result))
+ if (!function_exists('phpbb_get_banned_user_ids'))
{
- unset($recipients[$row['ban_userid']]);
+ include($phpbb_root_path . 'includes/functions_user.' . $phpEx);
}
- $db->sql_freeresult($result);
+ $banned_users = phpbb_get_banned_user_ids(array_keys($recipients));
+ $recipients = array_diff(array_keys($recipients), $banned_users);
if (!sizeof($recipients))
{
@@ -1693,7 +1688,7 @@ function pm_notification($mode, $author, $recipients, $subject, $message, $msg_i
$sql = 'SELECT user_id, username, user_email, user_lang, user_notify_pm, user_notify_type, user_jabber
FROM ' . USERS_TABLE . '
- WHERE ' . $db->sql_in_set('user_id', array_map('intval', array_keys($recipients)));
+ WHERE ' . $db->sql_in_set('user_id', $recipients);
$result = $db->sql_query($sql);
$msg_list_ary = array();
diff --git a/phpBB/includes/functions_user.php b/phpBB/includes/functions_user.php
index 509e1a953c..18452c27e9 100644
--- a/phpBB/includes/functions_user.php
+++ b/phpBB/includes/functions_user.php
@@ -3691,3 +3691,36 @@ function remove_newly_registered($user_id, $user_data = false)
return $user_data['group_id'];
}
+
+/**
+* Gets user ids of currently banned registered users.
+*
+* @param array $user_ids Array of users' ids to check for banning,
+* leave empty to get complete list of banned ids
+* @return array Array of banned users' ids if any, empty array otherwise
+*/
+function phpbb_get_banned_user_ids($user_ids = array())
+{
+ global $db;
+
+ $sql_user_ids = (!empty($user_ids)) ? $db->sql_in_set('ban_userid', $user_ids) : 'ban_userid <> 0';
+
+ // Get banned User ID's
+ // Ignore stale bans which were not wiped yet
+ $banned_ids_list = array();
+ $sql = 'SELECT ban_userid
+ FROM ' . BANLIST_TABLE . "
+ WHERE $sql_user_ids
+ AND ban_exclude <> 1
+ AND (ban_end > " . time() . '
+ OR ban_end = 0)';
+ $result = $db->sql_query($sql);
+ while ($row = $db->sql_fetchrow($result))
+ {
+ $user_id = (int) $row['ban_userid'];
+ $banned_ids_list[$user_id] = $user_id;
+ }
+ $db->sql_freeresult($result);
+
+ return $banned_ids_list;
+}
diff --git a/phpBB/includes/mcp/mcp_topic.php b/phpBB/includes/mcp/mcp_topic.php
index 598b470663..d4ba89b04c 100644
--- a/phpBB/includes/mcp/mcp_topic.php
+++ b/phpBB/includes/mcp/mcp_topic.php
@@ -49,6 +49,16 @@ function mcp_topic_view($id, $mode, $action)
$submitted_id_list = request_var('post_ids', array(0));
$checked_ids = $post_id_list = request_var('post_id_list', array(0));
+ // Resync Topic?
+ if ($action == 'resync')
+ {
+ if (!function_exists('mcp_resync_topics'))
+ {
+ include($phpbb_root_path . 'includes/mcp/mcp_forum.' . $phpEx);
+ }
+ mcp_resync_topics(array($topic_id));
+ }
+
// Split Topic?
if ($action == 'split_all' || $action == 'split_beyond')
{
@@ -319,6 +329,7 @@ function mcp_topic_view($id, $mode, $action)
'S_CAN_APPROVE' => ($has_unapproved_posts && $auth->acl_get('m_approve', $topic_info['forum_id'])) ? true : false,
'S_CAN_LOCK' => ($auth->acl_get('m_lock', $topic_info['forum_id'])) ? true : false,
'S_CAN_REPORT' => ($auth->acl_get('m_report', $topic_info['forum_id'])) ? true : false,
+ 'S_CAN_SYNC' => $auth->acl_get('m_', $topic_info['forum_id']),
'S_REPORT_VIEW' => ($action == 'reports') ? true : false,
'S_MERGE_VIEW' => ($action == 'merge') ? true : false,
'S_SPLIT_VIEW' => ($action == 'split') ? true : false,
diff --git a/phpBB/includes/startup.php b/phpBB/includes/startup.php
index de55db2960..9c4e1374ba 100644
--- a/phpBB/includes/startup.php
+++ b/phpBB/includes/startup.php
@@ -19,7 +19,8 @@ if (!defined('E_DEPRECATED'))
{
define('E_DEPRECATED', 8192);
}
-error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED);
+$level = E_ALL & ~E_NOTICE & ~E_DEPRECATED;
+error_reporting($level);
/*
* Remove variables created by register_globals from the global scope
diff --git a/phpBB/language/en/mcp.php b/phpBB/language/en/mcp.php
index 664365b1ec..bd25d403ab 100644
--- a/phpBB/language/en/mcp.php
+++ b/phpBB/language/en/mcp.php
@@ -238,6 +238,7 @@ $lang = array_merge($lang, array(
'NO_POST' => 'You have to select a post in order to warn the user for a post.',
'NO_POST_REPORT' => 'This post was not reported.',
'NO_POST_SELECTED' => 'You must select at least one post to perform this action.',
+ 'NO_POSTS_QUEUE' => 'There are no posts waiting for approval.',
'NO_REASON_DISAPPROVAL' => 'Please give an appropriate reason for disapproval.',
'NO_REPORT' => 'No report found',
'NO_REPORTS' => 'No reports found',
diff --git a/phpBB/memberlist.php b/phpBB/memberlist.php
index cf2cb5b06d..741ac2f430 100644
--- a/phpBB/memberlist.php
+++ b/phpBB/memberlist.php
@@ -1347,6 +1347,7 @@ switch ($mode)
if ($mode)
{
$params[] = "mode=$mode";
+ $u_first_char_params[] = "mode=$mode";
}
$sort_params[] = "mode=$mode";
diff --git a/phpBB/styles/prosilver/template/mcp_queue.html b/phpBB/styles/prosilver/template/mcp_queue.html
index 5f16ebe7d0..f86678ebe4 100644
--- a/phpBB/styles/prosilver/template/mcp_queue.html
+++ b/phpBB/styles/prosilver/template/mcp_queue.html
@@ -78,7 +78,7 @@
</li>
</ul>
<!-- ELSE -->
- <p class="notopics"><strong><!-- IF S_TOPICS -->{L_NO_TOPICS_QUEUE}<!-- ELSE -->{L_UNAPPROVED_POSTS_ZERO_TOTAL}<!-- ENDIF --></strong></p>
+ <p class="notopics"><strong><!-- IF S_TOPICS -->{L_NO_TOPICS_QUEUE}<!-- ELSE -->{L_NO_POSTS_QUEUE}<!-- ENDIF --></strong></p>
<!-- ENDIF -->
<span class="corners-bottom"><span></span></span></div>
diff --git a/phpBB/styles/prosilver/template/mcp_topic.html b/phpBB/styles/prosilver/template/mcp_topic.html
index 6943dd41b3..85c87b8cca 100644
--- a/phpBB/styles/prosilver/template/mcp_topic.html
+++ b/phpBB/styles/prosilver/template/mcp_topic.html
@@ -158,6 +158,7 @@ onload_functions.push('subPanels()');
<!-- IF S_CAN_DELETE --><option value="delete_post">{L_DELETE_POSTS}</option><!-- ENDIF -->
<!-- IF S_CAN_MERGE --><option value="merge_posts"<!-- IF S_MERGE_VIEW --> selected="selected"<!-- ENDIF -->>{L_MERGE_POSTS}</option><!-- ENDIF -->
<!-- IF S_CAN_SPLIT --><option value="split_all"<!-- IF S_SPLIT_VIEW --> selected="selected"<!-- ENDIF -->>{L_SPLIT_POSTS}</option><option value="split_beyond">{L_SPLIT_AFTER}</option><!-- ENDIF -->
+ <!-- IF S_CAN_SYNC --><option value="resync">{L_RESYNC}</option><!-- ENDIF -->
</select>&nbsp;
<input class="button1" type="submit" name="mcp_topic_submit" value="{L_SUBMIT}" />
<div><a href="#" onclick="marklist('mcp', 'post', true); return false;">{L_MARK_ALL}</a> :: <a href="#" onclick="marklist('mcp', 'post', false); return false;">{L_UNMARK_ALL}</a></div>
diff --git a/phpBB/styles/prosilver/template/memberlist_view.html b/phpBB/styles/prosilver/template/memberlist_view.html
index 4b41693ded..f10ec64975 100644
--- a/phpBB/styles/prosilver/template/memberlist_view.html
+++ b/phpBB/styles/prosilver/template/memberlist_view.html
@@ -69,7 +69,7 @@
<!-- IF U_JABBER and S_JABBER_ENABLED --><dt>{L_JABBER}:</dt> <dd><a href="{U_JABBER}" onclick="popup(this.href, 550, 320); return false;">{L_SEND_JABBER_MESSAGE}</a></dd><!-- ELSEIF USER_JABBER --><dt>{L_JABBER}:</dt> <dd>{USER_JABBER}</dd><!-- ENDIF -->
<!-- IF S_PROFILE_FIELD1 -->
<!-- NOTE: Use a construct like this to include admin defined profile fields. Replace FIELD1 with the name of your field. -->
- <dt>{postrow.PROFILE_FIELD1_NAME}:</dt> <dd>{postrow.PROFILE_FIELD1_VALUE}</dd>
+ <dt>{PROFILE_FIELD1_NAME}:</dt> <dd>{PROFILE_FIELD1_VALUE}</dd>
<!-- ENDIF -->
</dl>
</div>
diff --git a/phpBB/styles/subsilver2/template/mcp_queue.html b/phpBB/styles/subsilver2/template/mcp_queue.html
index 6e39ccd272..d13af91888 100644
--- a/phpBB/styles/subsilver2/template/mcp_queue.html
+++ b/phpBB/styles/subsilver2/template/mcp_queue.html
@@ -27,7 +27,7 @@
</tr>
<!-- BEGINELSE -->
<tr>
- <td class="row1" colspan="4" height="30" align="center" valign="middle"><span class="gen"><!-- IF S_TOPICS -->{L_NO_TOPICS_QUEUE}<!-- ELSE -->{L_UNAPPROVED_POSTS_ZERO_TOTAL}<!-- ENDIF --></span></td>
+ <td class="row1" colspan="4" height="30" align="center" valign="middle"><span class="gen"><!-- IF S_TOPICS -->{L_NO_TOPICS_QUEUE}<!-- ELSE -->{L_NO_POSTS_QUEUE}<!-- ENDIF --></span></td>
</tr>
<!-- END postrow -->
<tr>
diff --git a/phpBB/styles/subsilver2/template/mcp_topic.html b/phpBB/styles/subsilver2/template/mcp_topic.html
index 83c95c4ff9..8ff648da39 100644
--- a/phpBB/styles/subsilver2/template/mcp_topic.html
+++ b/phpBB/styles/subsilver2/template/mcp_topic.html
@@ -135,6 +135,7 @@
<!-- IF S_CAN_DELETE --><option value="delete_post">{L_DELETE_POSTS}</option><!-- ENDIF -->
<!-- IF S_CAN_MERGE --><option value="merge_posts"<!-- IF ACTION eq 'merge' --> selected="selected"<!-- ENDIF -->>{L_MERGE_POSTS}</option><!-- ENDIF -->
<!-- IF S_CAN_SPLIT --><option value="split_all"<!-- IF ACTION eq 'split' --> selected="selected"<!-- ENDIF -->>{L_SPLIT_POSTS}</option><option value="split_beyond">{L_SPLIT_AFTER}</option><!-- ENDIF -->
+ <!-- IF S_CAN_SYNC --><option value="resync">{L_RESYNC}</option><!-- ENDIF -->
</select>&nbsp;<input class="btnmain" type="submit" name="mcp_topic_submit" value="{L_SUBMIT}" /></td>
</tr>
</table>
diff --git a/phpunit.xml.all b/phpunit.xml.all
index b835a38c20..fde3bbb1a7 100644
--- a/phpunit.xml.all
+++ b/phpunit.xml.all
@@ -14,10 +14,6 @@
<testsuites>
<testsuite name="phpBB Test Suite">
<directory suffix="_test.php">./tests/</directory>
- <exclude>./tests/functional</exclude>
- </testsuite>
- <testsuite name="phpBB Functional Tests">
- <directory suffix="_test.php" phpVersion="5.3.0" phpVersionOperator=">=">./tests/functional</directory>
</testsuite>
</testsuites>
diff --git a/phpunit.xml.dist b/phpunit.xml.dist
index da31dce5e3..27dee48aac 100644
--- a/phpunit.xml.dist
+++ b/phpunit.xml.dist
@@ -14,10 +14,6 @@
<testsuites>
<testsuite name="phpBB Test Suite">
<directory suffix="_test.php">./tests/</directory>
- <exclude>./tests/functional</exclude>
- </testsuite>
- <testsuite name="phpBB Functional Tests">
- <directory suffix="_test.php" phpVersion="5.3.0" phpVersionOperator=">=">./tests/functional</directory>
</testsuite>
</testsuites>
diff --git a/phpunit.xml.functional b/phpunit.xml.functional
index 91d569e65b..9facbcff8b 100644
--- a/phpunit.xml.functional
+++ b/phpunit.xml.functional
@@ -14,10 +14,6 @@
<testsuites>
<testsuite name="phpBB Test Suite">
<directory suffix="_test.php">./tests/</directory>
- <exclude>./tests/functional</exclude>
- </testsuite>
- <testsuite name="phpBB Functional Tests">
- <directory suffix="_test.php" phpVersion="5.3.0" phpVersionOperator=">=">./tests/functional</directory>
</testsuite>
</testsuites>
diff --git a/tests/bootstrap.php b/tests/bootstrap.php
index 302701e3b3..f103d8f15a 100644
--- a/tests/bootstrap.php
+++ b/tests/bootstrap.php
@@ -25,8 +25,4 @@ require_once 'test_framework/phpbb_test_case_helpers.php';
require_once 'test_framework/phpbb_test_case.php';
require_once 'test_framework/phpbb_database_test_case.php';
require_once 'test_framework/phpbb_database_test_connection_manager.php';
-
-if (version_compare(PHP_VERSION, '5.3.0-dev', '>='))
-{
- require_once 'test_framework/phpbb_functional_test_case.php';
-}
+require_once 'test_framework/phpbb_functional_test_case.php';
diff --git a/travis/phpunit-mysql-travis.xml b/travis/phpunit-mysql-travis.xml
new file mode 100644
index 0000000000..79215c8de1
--- /dev/null
+++ b/travis/phpunit-mysql-travis.xml
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<phpunit backupGlobals="true"
+ backupStaticAttributes="true"
+ colors="true"
+ convertErrorsToExceptions="true"
+ convertNoticesToExceptions="true"
+ convertWarningsToExceptions="true"
+ processIsolation="false"
+ stopOnFailure="false"
+ syntaxCheck="true"
+ strict="true"
+ bootstrap="../tests/bootstrap.php">
+ <testsuites>
+ <testsuite name="phpBB Test Suite">
+ <directory suffix="_test.php">../tests/</directory>
+ </testsuite>
+ </testsuites>
+
+ <groups>
+ <exclude>
+ <group>slow</group>
+ </exclude>
+ </groups>
+
+ <php>
+ <const name="dbms" value="mysqli"/>
+ <const name="dbhost" value="0.0.0.0" />
+ <const name="dbport" value="3306" />
+ <const name="dbname" value="phpbb_tests" />
+ <const name="dbuser" value="root" />
+ <const name="dbpasswd" value="" />
+ <const name="table_prefix" value="phpbb_"/>
+ </php>
+</phpunit>
diff --git a/travis/phpunit-postgres-travis.xml b/travis/phpunit-postgres-travis.xml
new file mode 100644
index 0000000000..02db76ae78
--- /dev/null
+++ b/travis/phpunit-postgres-travis.xml
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<phpunit backupGlobals="true"
+ backupStaticAttributes="true"
+ colors="true"
+ convertErrorsToExceptions="true"
+ convertNoticesToExceptions="true"
+ convertWarningsToExceptions="true"
+ processIsolation="false"
+ stopOnFailure="false"
+ syntaxCheck="true"
+ strict="true"
+ bootstrap="../tests/bootstrap.php">
+ <testsuites>
+ <testsuite name="phpBB Test Suite">
+ <directory suffix="_test.php">../tests/</directory>
+ </testsuite>
+ </testsuites>
+
+ <groups>
+ <exclude>
+ <group>slow</group>
+ </exclude>
+ </groups>
+
+ <php>
+ <!-- "Real" test database -->
+ <!-- uncomment, otherwise sqlite memory runs -->
+ <const name="dbms" value="postgres"/>
+ <const name="dbhost" value="localhost" />
+ <const name="dbport" value="5432" />
+ <const name="dbname" value="phpbb_tests" />
+ <const name="dbuser" value="postgres" />
+ <const name="dbpasswd" value="" />
+ <const name="table_prefix" value="phpbb_"/>
+ </php>
+</phpunit>