mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-25 00:05:29 +00:00
61f1754d14
Not all installations will have a user with the id of 2, like jenkins. At some point User::getOption is called, which requires loading the user from the database, except it doesn't exist. At which point the user id is reset to 0, so it becomes an anonymous user, breaking the test. Since the MediaWiki test runner automatically creates a test user, we can safely assume that there is a user with the id 1. The other failure was due to that $wgUser may not always be 127.0.0.1. The test now directly just calls $wgUser to avoid issues if another test has altered the global state. Change-Id: Iacf904d04f1ff5aaf584cb98c3083ef6d7d89cea |
||
---|---|---|
api | ||
controller | ||
db_patches | ||
formatters | ||
includes | ||
jobs | ||
maintenance | ||
model | ||
modules | ||
special | ||
tests | ||
.gitignore | ||
.gitreview | ||
.jshintrc | ||
Echo.alias.php | ||
Echo.i18n.php | ||
Echo.php | ||
echo.sql | ||
Hooks.php | ||
Notifier.php |