Re: [PEAR-QA] is_a() and the need for improved testing
[email protected] ("Daniel O'Connor") Mon, 29 Aug 2011 10:34:20 +0930
| Newsgroups | php.pear.qa |
|---|---|
| Message-ID | <CAJsZyFAQQ=J9LF3cn86QsjP5Cw3GQCsP=68xc3GcrW0fu=GKDQ@mail.gmail.com> |
On Sat, Aug 27, 2011 at 9:44 AM, Daniel Convissor < [email protected]> wrote: > Hi Folks: > > As you may have noticed or heard about, is_a() was modified in 5.3.7. > One issue was adding a warning if the first argument wasn't an object, > though that was removed before 5.3.7 went out the door. Another issue > is autoload being called if the first argument is a string: > https://bugs.php.net/bug.php?id=55475 > http://marc.info/?t=131399222400001&r=1&w=2 > http://marc.info/?l=php-internals&m=131415106807521&w=2 > > Un-reverting the fix for PEAR bug 18656 (done in r313340) (or something > along those lines) PLUS fixing the other uses of is_a() througout pear-core > and getting a new release out the door seems prudent. > > Then Alan provided a list of all uses of is_a() in all PEAR packages: > http://marc.info/?l=php-internals&m=131432741919689&w=2 > I've take care of the is_a() usage in DB and XML_RPC and will get releases > out soon. > > That aside, recent discussions on internals are touching on the need to > improve testing of PHP as it is being developed and released. To that > end, I figured I'd take a look at PEAR's automated testing to ensure > PEAR::DB's tests were working properly. They were not, so I adjusted > them. > > I'll add to the script producing http://test.pear.php.net/unit-test-results/deprecated.txt shortly. Alan; what's your method? Grep for all instances of is_a("*"), is_a('*')? What other patterns are clearly "wrong"?