mediawiki-extensions-AbuseF.../tests/phpunit
Daimona Eaytoy 416dcd9ba3 Simplify ViewEdit, round 2
- Add a helper method to output an unrecoverable error, comprising a
   button to go back to the filters list;
- Move the token check to attemptSave, so to make the conditionals
  easier to read, and group errors together
- Make buildFilterEditor take an HTML parameter for the error, so the
  caller can specify whether it's error or warning
- Move the check for non-existing filters out of buildFilterEditor
- Add a bunch of typehints
- Don't set af_throttled and af_hit_count in the empty row template, but
  set af_deleted (these are only used in buildFilterEditor)
- Make AbuseFilter::translateFromHistory consistently include the af_global
  property (previously it would only be set for global filters; this error
  was introduced when first implementing global filters)
- The only user-facing change is that, when trying to use a custom
  warning/disallow message on a global filter, this is now considered a
  non-fatal error, so we now show the editing interface (and not just an
  unrecoverable error).

The next step is resolving the @todo in buildFilterEditor about null
checks.

Change-Id: I9d217dcac3f4cc0b26e53eca735cc327d5efc76d
2020-10-23 13:00:43 +00:00
..
unit Simplify ViewEdit, round 2 2020-10-23 13:00:43 +00:00
AbuseFilterConsequencesTest.php Replace $wgAbuseFilterRestrictions with more specific variables 2020-10-22 13:38:59 +00:00
AbuseFilterCreateAccountTestTrait.php Add test traits for uploads and account creation 2020-10-04 13:16:58 +00:00
AbuseFilterDBTest.php Rewrite the VariableHolder code to translate deprecated variables 2020-09-29 15:06:14 +00:00
AbuseFilterParserEquivsetTest.php Introduce a KeywordsManager service 2020-09-28 23:03:52 +00:00
AbuseFilterSaveTest.php Replace $wgAbuseFilterRestrictions with more specific variables 2020-10-22 13:38:59 +00:00
AbuseFilterUploadTestTrait.php Add test traits for uploads and account creation 2020-10-04 13:16:58 +00:00
AbuseFilterVariableGeneratorDBTest.php Add test traits for uploads and account creation 2020-10-04 13:16:58 +00:00
UpdateVarDumpsTest.php updateVarDumps: avoid using services in the constructor 2020-10-03 23:23:37 +00:00