[so] [tema 5] Bug static file

Relu Dragan draganrelu at gmail.com
Sun May 21 23:08:30 EEST 2017


Am rezolvat pana la urma, problema era ca trebuia sa trimit header-ul http
de reply cu send-uri multiple.
Un singur send nu il trimitea pe tot cand rulam checker-ul spre deosebire
de rularea locala cand se trimitea tot header-ul deodata.

Multumesc,
Relu Dragan


2017-05-21 21:11 GMT+03:00 Relu Dragan <draganrelu at gmail.com>:

> Salut,
>
> Cand testez local cererea unui fisier  static cu wget prin comanda
> wget -t 1 "http://localhost:8888/static/file.txt" -o wget.log -O file.txt
> si verific cu diff sau cmp continutulul fisierelor totul este in regula.
> Insa testele 16-19 cateodata imi pica. M-am uitat in checker la codul
> acestor teste
> si am observat ca desi exit code-ul comenzii wget este intotdeauna 0, exit
> codul comenzii
> [ -s small00.dat ] este cateodata 1.
> De unde ar putea fi problema?
>
> Am atasat codul testului 16:
> test_get_small_file_wget()
> {
> init_test
>
> wget -t 1 "http://localhost:8888/$(basename $static_folder)/small00.dat" \
> -o $WGET_LOG -O small00.dat
> code1=$?
>
> [ -s small00.dat ]
> code2=$?
> basic_test test $code1 -eq 0 -a $code2 -eq 0
>
> rm small00.dat
> cleanup_test
> }
>
> Multumesc,
> Relu Dragan
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://cursuri.cs.pub.ro/pipermail/so/attachments/20170521/1b628c06/attachment.html>


More information about the so mailing list