In https://gerrit.wikimedia.org/r/#/q/Ifa7d943875f05088ef697a5a18ad292342a9b4ad the following shortcomings of https://gerrit.wikimedia.org/r/#/q/ FactoryArgTestTrait were discovered:
- [ ] getFactoryMethodName composes a default name that consists of `new` and the class-name. This works great for classes in the main namespace, however, it also includes the namespace of the class. For example for the class `MathoidChekcer `it currently generates the Method name `newMediaWiki\Extension\Math\InputCheck\MathoidChecker`
- [ ] counting of parameters only works if the ServiceOptions are passed as they are from the factory to the class instance. However, if one extracts the required wgGlobals in the factory and passes them, the parameter counting is confused.
See https://gerrit.wikimedia.org/r/#/q/Ifa7d943875f05088ef697a5a18ad292342a9b4ad for details