This commit is contained in:
Simon Cruanes 2024-12-02 15:49:08 -05:00
parent 0b34c966f7
commit 099777b593
No known key found for this signature in database
GPG key ID: EBFFF6F283F3A2B4
2 changed files with 7 additions and 18 deletions

View file

@ -38,17 +38,13 @@ let test input_str =
let () = let () =
pf "T1\n"; pf "T1\n";
test test
"hello\r\n\ "hello--YOLO\n\
--YOLO\n\
\ world\n\ \ world\n\
\ what is the meaning of\r\n\ \ what is the meaning of--YOLOthis??--YOLOok ok ok--YOLO";
--YOLOthis??\r\n\
--YOLOok ok ok\r\n\
--YOLO";
pf "T2\n"; pf "T2\n";
test "\r\n--YOLO\r\n--YOLOah bon\r\n--YOLOaight\r\n--YOLO\r\n--YOLO"; test "--YOLO--YOLOah bon--YOLOaight--YOLO--YOLO";
pf "T3\n"; pf "T3\n";
test test
(spf "\r\n--YOLO%s\r\n--YOLO\r\n--YOLO%s\r\n--YOLO%s" (String.make 400 'a') (spf "--YOLO%s--YOLO--YOLO%s--YOLO%s" (String.make 400 'a')
(String.make 512 'b') (String.make 400 'c')); (String.make 512 'b') (String.make 400 'c'));
() ()

View file

@ -41,34 +41,27 @@ let test input_str =
let () = let () =
pf "T1\n"; pf "T1\n";
test test
"\r\n\ "--YOLO\r\n\
--YOLO\r\n\
some-super-cool: header here\r\n\ some-super-cool: header here\r\n\
ohlook: here\r\n\ ohlook: here\r\n\
\r\n\ \r\n\
and now for the b-o-d-y 👏\n\ and now for the b-o-d-y 👏\n\
\r\n\
--YOLO\r\n\ --YOLO\r\n\
more: headers\r\n\ more: headers\r\n\
\r\n\ \r\n\
and another body\r\n\ and another body\r\n\
\r\n\
--YOLO--"; --YOLO--";
pf "T1\n"; pf "T1\n";
test test
(spf (spf
"\r\n\ "--YOLO\r\n\
--YOLO\r\n\
some-super-cool: header here\r\n\ some-super-cool: header here\r\n\
ohlook: here\r\n\ ohlook: here\r\n\
\r\n\ \r\n\
and now for the bigger body:\n\ and now for the bigger body:\n\
%s\n\ %s\n\
\r\n\
--YOLO\r\n\ --YOLO\r\n\
more: headers\r\n\ more: headers\r\n\
\r\n\ \r\n\
and another body\r\n\ and another body--YOLO--" (String.make 500 'a'));
--YOLO--"
(String.make 500 'a'));
() ()