import zend standard tests
[hiphop-php.git] / hphp / test / zend / bad / ext-standard-file / fgets_basic.php.expectf
blob9cd00be4f4af9c40412badcd257b776057733469
1 *** Testing fgets() : basic functionality ***
3 -- Testing fgets() with file opened using mode r --
4 -- File content type : numeric --
5 -- fgets() with default length, file pointer at 0 --
6 string(50) "22222222222222222222222222222222222222222222222222"
7 int(50)
8 bool(true)
9 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
10 bool(true)
11 string(22) "2222222222222222222222"
12 int(22)
13 bool(false)
14 -- File content type : text --
15 -- fgets() with default length, file pointer at 0 --
16 string(50) "text text text text text text text text text text "
17 int(50)
18 bool(true)
19 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
20 bool(true)
21 string(22) "text text text text te"
22 int(22)
23 bool(false)
24 -- File content type : text_with_new_line --
25 -- fgets() with default length, file pointer at 0 --
26 string(5) "line
28 int(5)
29 bool(false)
30 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
31 bool(true)
32 string(5) "line
34 int(5)
35 bool(false)
36 -- File content type : alphanumeric --
37 -- fgets() with default length, file pointer at 0 --
38 string(50) "ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 "
39 int(50)
40 bool(true)
41 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
42 bool(true)
43 string(22) "ab12 ab12 ab12 ab12 ab"
44 int(22)
45 bool(false)
47 -- Testing fgets() with file opened using mode rb --
48 -- File content type : numeric --
49 -- fgets() with default length, file pointer at 0 --
50 string(50) "22222222222222222222222222222222222222222222222222"
51 int(50)
52 bool(true)
53 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
54 bool(true)
55 string(22) "2222222222222222222222"
56 int(22)
57 bool(false)
58 -- File content type : text --
59 -- fgets() with default length, file pointer at 0 --
60 string(50) "text text text text text text text text text text "
61 int(50)
62 bool(true)
63 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
64 bool(true)
65 string(22) "text text text text te"
66 int(22)
67 bool(false)
68 -- File content type : text_with_new_line --
69 -- fgets() with default length, file pointer at 0 --
70 string(5) "line
72 int(5)
73 bool(false)
74 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
75 bool(true)
76 string(5) "line
78 int(5)
79 bool(false)
80 -- File content type : alphanumeric --
81 -- fgets() with default length, file pointer at 0 --
82 string(50) "ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 "
83 int(50)
84 bool(true)
85 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
86 bool(true)
87 string(22) "ab12 ab12 ab12 ab12 ab"
88 int(22)
89 bool(false)
91 -- Testing fgets() with file opened using mode rt --
92 -- File content type : numeric --
93 -- fgets() with default length, file pointer at 0 --
94 string(50) "22222222222222222222222222222222222222222222222222"
95 int(50)
96 bool(true)
97 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
98 bool(true)
99 string(22) "2222222222222222222222"
100 int(22)
101 bool(false)
102 -- File content type : text --
103 -- fgets() with default length, file pointer at 0 --
104 string(50) "text text text text text text text text text text "
105 int(50)
106 bool(true)
107 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
108 bool(true)
109 string(22) "text text text text te"
110 int(22)
111 bool(false)
112 -- File content type : text_with_new_line --
113 -- fgets() with default length, file pointer at 0 --
114 string(5) "line
116 int(5)
117 bool(false)
118 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
119 bool(true)
120 string(5) "line
122 int(5)
123 bool(false)
124 -- File content type : alphanumeric --
125 -- fgets() with default length, file pointer at 0 --
126 string(50) "ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 "
127 int(50)
128 bool(true)
129 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
130 bool(true)
131 string(22) "ab12 ab12 ab12 ab12 ab"
132 int(22)
133 bool(false)
135 -- Testing fgets() with file opened using mode r+ --
136 -- File content type : numeric --
137 -- fgets() with default length, file pointer at 0 --
138 string(50) "22222222222222222222222222222222222222222222222222"
139 int(50)
140 bool(true)
141 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
142 bool(true)
143 string(22) "2222222222222222222222"
144 int(22)
145 bool(false)
146 -- File content type : text --
147 -- fgets() with default length, file pointer at 0 --
148 string(50) "text text text text text text text text text text "
149 int(50)
150 bool(true)
151 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
152 bool(true)
153 string(22) "text text text text te"
154 int(22)
155 bool(false)
156 -- File content type : text_with_new_line --
157 -- fgets() with default length, file pointer at 0 --
158 string(5) "line
160 int(5)
161 bool(false)
162 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
163 bool(true)
164 string(5) "line
166 int(5)
167 bool(false)
168 -- File content type : alphanumeric --
169 -- fgets() with default length, file pointer at 0 --
170 string(50) "ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 "
171 int(50)
172 bool(true)
173 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
174 bool(true)
175 string(22) "ab12 ab12 ab12 ab12 ab"
176 int(22)
177 bool(false)
179 -- Testing fgets() with file opened using mode r+b --
180 -- File content type : numeric --
181 -- fgets() with default length, file pointer at 0 --
182 string(50) "22222222222222222222222222222222222222222222222222"
183 int(50)
184 bool(true)
185 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
186 bool(true)
187 string(22) "2222222222222222222222"
188 int(22)
189 bool(false)
190 -- File content type : text --
191 -- fgets() with default length, file pointer at 0 --
192 string(50) "text text text text text text text text text text "
193 int(50)
194 bool(true)
195 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
196 bool(true)
197 string(22) "text text text text te"
198 int(22)
199 bool(false)
200 -- File content type : text_with_new_line --
201 -- fgets() with default length, file pointer at 0 --
202 string(5) "line
204 int(5)
205 bool(false)
206 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
207 bool(true)
208 string(5) "line
210 int(5)
211 bool(false)
212 -- File content type : alphanumeric --
213 -- fgets() with default length, file pointer at 0 --
214 string(50) "ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 "
215 int(50)
216 bool(true)
217 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
218 bool(true)
219 string(22) "ab12 ab12 ab12 ab12 ab"
220 int(22)
221 bool(false)
223 -- Testing fgets() with file opened using mode r+t --
224 -- File content type : numeric --
225 -- fgets() with default length, file pointer at 0 --
226 string(50) "22222222222222222222222222222222222222222222222222"
227 int(50)
228 bool(true)
229 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
230 bool(true)
231 string(22) "2222222222222222222222"
232 int(22)
233 bool(false)
234 -- File content type : text --
235 -- fgets() with default length, file pointer at 0 --
236 string(50) "text text text text text text text text text text "
237 int(50)
238 bool(true)
239 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
240 bool(true)
241 string(22) "text text text text te"
242 int(22)
243 bool(false)
244 -- File content type : text_with_new_line --
245 -- fgets() with default length, file pointer at 0 --
246 string(5) "line
248 int(5)
249 bool(false)
250 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
251 bool(true)
252 string(5) "line
254 int(5)
255 bool(false)
256 -- File content type : alphanumeric --
257 -- fgets() with default length, file pointer at 0 --
258 string(50) "ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 ab12 "
259 int(50)
260 bool(true)
261 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
262 bool(true)
263 string(22) "ab12 ab12 ab12 ab12 ab"
264 int(22)
265 bool(false)
266 Done