Add test for User::isBlockedFrom
authorThalia <thalia.e.chan@googlemail.com>
Tue, 5 Feb 2019 17:20:58 +0000 (17:20 +0000)
committerThalia <thalia.e.chan@googlemail.com>
Tue, 5 Feb 2019 18:13:32 +0000 (18:13 +0000)
commitc38f247149efef1debc3353a0c588338283cad28
tree957baf2f3ab566959f0f85d69f4eac8532f69fba
parent1762dcfd2f1bc8c33e059dba076c1af1503f9378
Add test for User::isBlockedFrom

In the complicated decision tree for checking if a blocked
user is blocked from their talk page, one situation was not
being tested: there's a partial block to the user talk
namespace, the block is flagged as allowing a user to edit
their talk page, BUT $wgBlockAllowsUTEdit is false. In this
circumstance, the user should be blocked from editing their
talk page, as outlined in T210475.

Also, fix whitespace and make messages clearer, since this
is now quite complicated.

Change-Id: I234f3019d55a6da0da091a2eaae6c791be01b436
tests/phpunit/includes/user/UserTest.php