Re: Remove zpp variation tests

From: Date: Fri, 01 Feb 2019 16:00:14 +0000
Subject: Re: Remove zpp variation tests
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-103989@lists.php.net to get a copy of this message
On Wed, Jan 30, 2019 at 7:39 PM Stanislav Malyshev <smalyshev@gmail.com> wrote: > Hi! > > > This test passes a certain set of input values of different types to a > > function with a zpp string argument and observes the behavior. Of course, > > there are also hundreds of other functions that accept strings through > zpp > > and the behavior is always going to be the same. > > This is true for functions that use standard zpp handling, but there are > a number of them that use custom zpp handling, and for those there could > be corner cases which aren't handled properly. In fact, I've seen some > zpp-using functions that so not properly handle nulls, empty strings, > etc. as arguments (zpp works fine, it's the part past zpp that fails). > So we need to be careful and remove only those tests that are indeed > handled by zpp and not the code beyond it that does need to be tested, > and not remove tests which cover custom argument handling. > Yes, we shouldn't remove tests for custom argument handling. I've started working on this in https://github.com/php/php-src/pull/3783 and try to check for all tests whether this is a simple zpp argument or not. I'm also switching some cases to use zpp on the PHP 8 branch, where functions had some custom argument handling for no good reason. Nikita

« previous php.internals (#103989) next »