com php-src: Improved code coverage of explode function: ext/standard/tests/strings/explode_variation7.phpt

From: Date: Mon, 29 Jun 2015 21:49:41 +0000
Subject: com php-src: Improved code coverage of explode function: ext/standard/tests/strings/explode_variation7.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-87635@lists.php.net to get a copy of this message
Commit: 1b1a86c415aea8146070613638fac818b65b8656 Author: Edgar R. Sandi <edgar.r.sandi@gmail.com> Mon, 29 Jun 2015 17:34:57 -0300 Committer: Christoph M. Becker <cmb@php.net> Mon, 29 Jun 2015 23:49:41 +0200 Parents: d2bc45f6b30542adc5d17fdee604822e011be333 Branches: PHP-5.6 master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=1b1a86c415aea8146070613638fac818b65b8656 Log: Improved code coverage of explode function Changed paths: A ext/standard/tests/strings/explode_variation7.phpt Diff: diff --git a/ext/standard/tests/strings/explode_variation7.phpt b/ext/standard/tests/strings/explode_variation7.phpt new file mode 100644 index 0000000..d645c6c --- /dev/null +++ b/ext/standard/tests/strings/explode_variation7.phpt @@ -0,0 +1,18 @@ +--TEST-- +Test explode() function : usage variations - when $string length is greater than +EXPLODE_ALLOC_STEP (64) and the $limit is negative +--CREDITS-- +edgarsandi - <edgar.r.sandi@gmail.com> +--FILE-- +<?php + +/* Prototype : array explode ( string $delimiter , string $string [, int $limit ] ) + * Description: Split a string by string.. + * Source code: ext/standard/string.c +*/ + +var_dump(count(explode('|', implode(range(1,65),'|'), -1))); + +?> +--EXPECT-- +int(64)

« previous php.cvs (#87635) next »