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 |
||
|---|---|---|
| .. | ||
| AutoloadGenerator.php | ||
| BatchRowIterator.php | ||
| BatchRowUpdate.php | ||
| BatchRowWriter.php | ||
| ClassCollector.php | ||
| ExecutableFinder.php | ||
| FileContentsHasher.php | ||
| MWCryptHKDF.php | ||
| MWCryptRand.php | ||
| MWFileProps.php | ||
| MWRestrictions.php | ||
| README | ||
| RowUpdateGenerator.php | ||
| UIDGenerator.php | ||
| UrlUtils.php | ||
| ZipDirectoryReader.php | ||
| 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.