wiki.techinc.nl/includes/utils
Timo Tijhof 4dd2b8d885 UrlUtils: Simplify and increase test coverage
Follows-up I31f1403ab40c79ab270c417.

* Make the test cases less dynamic. It was approaching the same
  kind of complexity as the source code, thus reducing confidence
  in the test.

* Make the test cases more explicit. A good test can be read without
  executing it and show plainly what the expected output are.
  Use little to no indirection, favouring small amounts of
  duplication when in doubt.

* Increase coverage of the "non-standard HTTPS port" configuration,
  by removing the two hardcoded assertions for it, in favour of
  including it in the overal test matrix and applying the same set
  of default cases to it as the other configurations under test.

* There are now 306 instead of 2355 generated test cases, but
  the code coverage of UrlUtils.php remains identical
  at 98.28% (171/174 lines).

Change-Id: I755c017964757b9aab5ebeabd80be5664be48798
2022-05-16 14:10:31 +10:00
..
AutoloadGenerator.php Fix many typos in comments 2022-05-10 12:46:11 +00:00
BatchRowIterator.php
BatchRowUpdate.php
BatchRowWriter.php
ClassCollector.php
ExecutableFinder.php
FileContentsHasher.php
MWCryptHKDF.php
MWCryptRand.php
MWFileProps.php phan: Disable null_casts_as_any_type setting 2022-03-21 18:25:07 +00:00
MWRestrictions.php
README
RowUpdateGenerator.php
UIDGenerator.php
UrlUtils.php UrlUtils: Simplify and increase test coverage 2022-05-16 14:10:31 +10:00
ZipDirectoryReader.php Call ZipDirectoryReader from MimeAnalyzer 2022-05-03 14:43:26 +10:00
ZipDirectoryReaderError.php

The classes in this directory are general utilities for use by any part of
MediaWiki. They do not favour any particular user interface and are not
constrained to serve any particular feature. This is similar to includes/libs,
except that some dependency on the MediaWiki framework (such as the use of
MWException, Status or wfDebug()) disqualifies them from use outside of
MediaWiki without modification.

Utilities should not use global configuration variables, rather they should rely
on the caller to configure their behaviour.