Add tests for ApiFormatBase
authorBrad Jorsch <bjorsch@wikimedia.org>
Wed, 3 Jan 2018 18:27:37 +0000 (13:27 -0500)
committerBrad Jorsch <bjorsch@wikimedia.org>
Wed, 3 Jan 2018 21:08:12 +0000 (16:08 -0500)
commita8f5964cfef4e6209cf6dd55a28b5ed91ee3a04b
tree8d33f2d5cbac25bd74454454ec9de3fe13b10bf3
parent9106f072f130deef73e6bbcf9a1190ae489269cc
Add tests for ApiFormatBase

Ensuring proper behavior of the base class lets comprehensive tests of
subclasses be simpler.

This also adjusts ApiFormatTestBase to be a bit more usable, passing an
array of options through to encodeData() instead of just a class name.
And removes the unused 'SKIP' from testGeneralEncoding, but allows
expecting an exception (for use in I63ce42dd).

Change-Id: Ib2a1fa0b04860b09105376881ff8411f9534c453
tests/phpunit/includes/api/format/ApiFormatBaseTest.php [new file with mode: 0644]
tests/phpunit/includes/api/format/ApiFormatTestBase.php