USING: accessors continuations http http.server io.encodings.utf8 io.encodings.binary io.streams.string kernel math sequences tools.test ; IN: http.server.tests [ t ] [ [ \ + first ] [ <500> ] recover response? ] unit-test [ "text/plain; charset=ASCII" ] [ "text/plain" >>content-type "ASCII" >>content-charset unparse-content-type ] unit-test [ "text/xml; charset=UTF-8" ] [ "text/xml" >>content-type unparse-content-type ] unit-test [ "image/jpeg" ] [ "image/jpeg" >>content-type unparse-content-type ] unit-test [ "application/octet-stream" ] [ unparse-content-type ] unit-test [ t ] [ { "GET / HTTP/1.1" "connection: close" "host: 127.0.0.1:55532" "user-agent: Factor http.client" } [ "\n" join ] [ "\r\n" join ] bi [ [ read-request ] with-string-reader ] bi@ = ] unit-test