If you don't do this test, it will just modify self::$patentScraper. But if you do, and you call createPatentScraper() again with different argument(s), it won't return the new instance with the new client/new config/new path. The same old instance will remain. So, it all depends on what you want. The most important here is that you should make sure only one class handles your app.