Re: Re: run-tests.php

From: Date: Fri, 14 Sep 2007 13:41:54 +0000
Subject: Re: Re: run-tests.php
References: 1 2 3 4 5 6 7  Groups: php.internals php.qa 
Request: Send a blank email to php-qa+get-45980@lists.php.net to get a copy of this message
OK, so basically it is impossible to fix the current regex to match what we want (I had a quick chat with the PCRE author and he thinks the same). I propose the following patch: http://web.ist.utl.pt/nuno.lopes/php_run_tests_%s.txt
The main changes are: '%s' => '[^\r\n]+'
Nice patch! The only thing i wonder about is why you disallow /r. Shouldn't we allow it to prevent problems? Or is it enough to take care of it only at line endings, and if so where are we doing that?
It's mainly because of the old Macs that used \r as line-ending. Anyway I think that probably you'll never want to match a single \r. If you want, well you can always use the EXPECTREGEX section, or the %c (match a char) or the new %a (match anything). Nuno

« previous php.qa (#45980) next »