|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2010-08-23 10:54 UTC] lstrojny@php.net
[2010-08-23 20:03 UTC] iekpo@php.net
[2011-06-04 04:13 UTC] iekpo@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 12:00:02 2025 UTC |
Description: ------------ To allow extending pecl/solr classes and allow mocking them with PHPUnit it would be required to remove the final keyword. Attached is a patch which does that for the current trunk version, but should also apply for 0.9.11. Reproduce code: --------------- class MockedSolrClient extends SolrClient{} $client = new MockedSolrClient(array('hostname' => 'localhost')); var_dump($client); Expected result: ---------------- object(MockedSolrClient)#1 (1) { ["_hashtable_index":"SolrClient":private]=> int(16995) } Actual result: -------------- Fatal error: Class MockedSolrClient may not inherit from final class (SolrClient) in Command line code on line 2