Update PermissionManagerTest and FormSpecialPageTestCase to use a
mock User object that returns a specified block.
Before this commit, these tests manipulate the public properties
User::mBlock and User::mBlockedby in order to change the user's
block. There is no advantage to doing this over mocking: it is not
more realistic, and is sensitive to changes in the code. These tests
need updating in order to deprecate public access to these properties
(see T229035).
Also, PermissionManager::testUserBlock is a large, complicated method
that tests three different things, so split it into three smaller
methods, each testing one thing:
* testCheckUserBlockActions: A blocked user is blocked/unblocked
correctly from certain actions, depending on their block.
* testCheckUserBlockMessage: The correct block message key and
parameters are returned, depending on the block.
* testCheckUserBlockEmailConfirmToEdit: A user is or isn't asked to
provide email confirmation in order to edit, as specified by the
config.
Change-Id: I0bb9252b476131c2b255d4c503c0dab5dfff94be