]> granicus.if.org Git - php/commitdiff
- more EOL fixes, don't use expectf
authorPierre Joye <pajoye@php.net>
Thu, 28 Jan 2010 00:37:20 +0000 (00:37 +0000)
committerPierre Joye <pajoye@php.net>
Thu, 28 Jan 2010 00:37:20 +0000 (00:37 +0000)
ext/standard/tests/file/fgetss_basic1.phpt
ext/standard/tests/file/fgetss_variation1-win32.phpt
ext/standard/tests/file/fgetss_variation3-win32.phpt
ext/standard/tests/file/fgetss_variation4.phpt
ext/standard/tests/file/fgetss_variation5-win32.phpt

index c220622594304eafe24f9e8478822571ef63e2d3..7ea0ed01a882984866c544e160d6bde95432591b 100644 (file)
@@ -22,7 +22,9 @@ is a heredoc string. <pg>ksklnm@@$$&$&^%&^%&^%&</pg>
 <html> html </html> <?php echo "php"; ?>
 EOT;
 
-
+if(substr(PHP_OS, 0, 3) == "WIN")  {
+       $string_with_tags = str_replace("\r",'', $string_with_tags);
+}
 /* try reading the file opened in different modes of reading */
 $file_modes = array("r","rb", "rt","r+", "r+b", "r+t");
 
index bc5c6c28c259945794b598a6f02a6a5cb5a46267..29973dbff94be8cde9044cf3086b41b39f999201 100644 (file)
@@ -36,6 +36,10 @@ this text contains some html tags <body> body </body> <br> br </br>
 this is the line with \n character. 
 EOT;
 
+if(substr(PHP_OS, 0, 3) == "WIN")  {
+       $string_with_tags = str_replace("\r",'', $string_with_tags);
+}
+
 $filename = dirname(__FILE__)."/fgetss_variation1.tmp";
 
 /* try reading the file opened in different modes of reading */
index b6ade02c867a0d147e3242ee2da6ae23bdafdc83..189c4cc208253b68c94e060d15b8593381d1cd4e 100644 (file)
@@ -35,6 +35,10 @@ this text contains some html tags <body> body </body> <br> br </br>
 this is the line with \n character. 
 EOT;
 
+if(substr(PHP_OS, 0, 3) == "WIN")  {
+       $string_with_tags = str_replace("\r",'', $string_with_tags);
+}
+
 $filename = dirname(__FILE__)."/fgetss_variation3.tmp"; 
 
 /* try reading the file opened in different modes of reading */
index 595041465e25b82b65c1a9bfa3c726149e26c099..f05e8840ac444ad0a7ad5da74c23acc8bf04a878 100644 (file)
@@ -1,5 +1,10 @@
 --TEST--
-Test fgetss() function : usage variations - read  modes, file pointer at EOF(bug#42126)
+Test fgetss() function : usage variations - read  modes, file pointer at EOF
+--SKIPIF--
+<?php
+if(substr(PHP_OS, 0, 3) == "WIN")
+  die("skip not for Windows");
+?>
 --FILE--
 <?php
 /*
index f1210633a929f03cce3245697b64e3c2bd25b1eb..9e00fe5f34d720119eca251d36bfbff0ce48be43 100644 (file)
@@ -33,6 +33,9 @@ this is a line with more than eighty character,want to check line splitting corr
 this text contains some html tags <body> body </body> <br> br </br>
 this is the line with \n character. 
 EOT;
+if(substr(PHP_OS, 0, 3) == "WIN")  {
+       $string_with_tags = str_replace("\r",'', $string_with_tags);
+}
 
 $filename = dirname(__FILE__)."/fgetss_variation5.tmp";