Test output for uri-common [ok]
Testing time: 0s
/home/mario/local/chicken-4.8.0.3/bin/csi -script run.scm < /dev/null -- testing uri-common -------------------------------------------------------- -- testing internal representations -------------------------------------- -- testing scheme ---------------------------------------------------- "http:" decoded as http ...................................... [ PASS] http encoded to "http:" ...................................... [ PASS] "" decoded as #f ............................................. [ PASS] #f encoded to "" ............................................. [ PASS] 4 tests completed in 0.0 seconds. 4 out of 4 (100%) tests passed. -- done testing scheme ----------------------------------------------- -- testing host ------------------------------------------------------ "http://a" decoded as "a" .................................... [ PASS] "a" encoded to "http://a" .................................... [ PASS] "http://a:8080" decoded as "a" ............................... [ PASS] "a" encoded to "http://a:8080" ............................... [ PASS] "//a" decoded as "a" ......................................... [ PASS] "a" encoded to "//a" ......................................... [ PASS] "/foo" decoded as #f ......................................... [ PASS] #f encoded to "/foo" ......................................... [ PASS] "http://" decoded as "" ...................................... [ PASS] "" encoded to "http://" ...................................... [ PASS] "http://:123" decoded as "" .................................. [ PASS] "" encoded to "http://:123" .................................. [ PASS] 12 tests completed in 0.001 seconds. 12 out of 12 (100%) tests passed. -- done testing host ------------------------------------------------- -- testing port ------------------------------------------------------ "http://a" decoded as 80 ..................................... [ PASS] 80 encoded to "http://a" ..................................... [ PASS] "http://a:8080" decoded as 8080 .............................. [ PASS] 8080 encoded to "http://a:8080" .............................. [ PASS] "https://a" decoded as 443 ................................... [ PASS] 443 encoded to "https://a" ................................... [ PASS] "https://a:1" decoded as 1 ................................... [ PASS] 1 encoded to "https://a:1" ................................... [ PASS] "//a" decoded as #f .......................................... [ PASS] #f encoded to "//a" .......................................... [ PASS] 10 tests completed in 0.001 seconds. 10 out of 10 (100%) tests passed. -- done testing port ------------------------------------------------- -- testing username -------------------------------------------------- "//foo" decoded as #f ........................................ [ PASS] #f encoded to "//foo" ........................................ [ PASS] "//@" decoded as "" .......................................... [ PASS] "" encoded to "//@" .......................................... [ PASS] "//foo@" decoded as "foo" .................................... [ PASS] "foo" encoded to "//foo@" .................................... [ PASS] "//foo:bar@" decoded as "foo" ................................ [ PASS] "foo" encoded to "//foo:bar@" ................................ [ PASS] "//foo:bar:qux@" decoded as "foo" ............................ [ PASS] "foo" encoded to "//foo:bar:qux@" ............................ [ PASS] "//foo%20bar@" decoded as "foo bar" .......................... [ PASS] "foo bar" encoded to "//foo%20bar@" .......................... [ PASS] "//foo%3Abar:qux@" decoded as "foo:bar" ...................... [ PASS] "foo:bar" encoded to "//foo%3Abar:qux@" ...................... [ PASS] "//foo%2Ebar@" decoded as "foo.bar" .......................... [ PASS] "foo.bar" encoded to "//foo.bar@" ............................ [ PASS] 16 tests completed in 0.002 seconds. 16 out of 16 (100%) tests passed. -- done testing username --------------------------------------------- -- testing password ------------------------------------------------- "//foo" decoded as #f ........................................ [ PASS] #f encoded to "//foo" ........................................ [ PASS] "//@" decoded as #f .......................................... [ PASS] #f encoded to "//@" .......................................... [ PASS] "//foo@" decoded as #f ....................................... [ PASS] #f encoded to "//foo@" ....................................... [ PASS] "//foo:bar@" decoded as "bar" ................................ [ PASS] "bar" encoded to "//foo:bar@" ................................ [ PASS] "//foo:bar:qux@" decoded as "bar:qux" ........................ [ PASS] "bar:qux" encoded to "//foo:bar:qux@" ........................ [ PASS] "//foo:bar%20qux@" decoded as "bar qux" ...................... [ PASS] "bar qux" encoded to "//foo:bar%20qux@" ...................... [ PASS] "//foo:bar%2Equx@" decoded as "bar.qux" ...................... [ PASS] "bar.qux" encoded to "//foo:bar.qux@" ........................ [ PASS] 14 tests completed in 0.001 seconds. 14 out of 14 (100%) tests passed. -- done testing password -------------------------------------------- -- testing path ------------------------------------------------------ "http://foo" decoded as (/ "") ............................... [ PASS] (/ "") encoded to "http://foo" ............................... [ PASS] "http://foo/" decoded as (/ "") .............................. [ PASS] (/ "") encoded to "http://foo/" .............................. [ PASS] "//foo" decoded as () ........................................ [ PASS] () encoded to "//foo" ........................................ [ PASS] "//foo/" decoded as (/ "") ................................... [ PASS] (/ "") encoded to "//foo/" ................................... [ PASS] "foo%20bar" decoded as ("foo bar") ........................... [ PASS] ("foo bar") encoded to "foo%20bar" ........................... [ PASS] "foo%2Fbar" decoded as ("foo/bar") ........................... [ PASS] ("foo/bar") encoded to "foo%2Fbar" ........................... [ PASS] "foo%2ebar" decoded as ("foo.bar") ........................... [ PASS] ("foo.bar") encoded to "foo.bar" ............................. [ PASS] "foo/bar%2Fqux" decoded as ("foo" "bar/qux") ................. [ PASS] ("foo" "bar/qux") encoded to "foo/bar%2Fqux" ................. [ PASS] "foo/" decoded as ("foo" "") ................................. [ PASS] ("foo" "") encoded to "foo/" ................................. [ PASS] "foo/bar:qux" decoded as ("foo" "bar:qux") ................... [ PASS] ("foo" "bar:qux") encoded to "foo/bar:qux" ................... [ PASS] "/foo%2Fbar" decoded as (/ "foo/bar") ........................ [ PASS] (/ "foo/bar") encoded to "/foo%2Fbar" ........................ [ PASS] "/foo/" decoded as (/ "foo" "") .............................. [ PASS] (/ "foo" "") encoded to "/foo/" .............................. [ PASS] "/foo:bar" decoded as (/ "foo:bar") .......................... [ PASS] (/ "foo:bar") encoded to "/foo:bar" .......................... [ PASS] 26 tests completed in 0.002 seconds. 26 out of 26 (100%) tests passed. -- done testing path ------------------------------------------------- -- testing query ---------------------------------------------------- "//" decoded as () ........................................... [ PASS] () encoded to "//" ........................................... [ PASS] "?" decoded as ((|| . #t)) ................................... [ PASS] ((|| . #t)) encoded to "?" ................................... [ PASS] "?foo" decoded as ((foo . #t)) ............................... [ PASS] ((foo . #t)) encoded to "?foo" ............................... [ PASS] "?foo?bar" decoded as ((foo?bar . #t)) ....................... [ PASS] ((foo?bar . #t)) encoded to "?foo?bar" ....................... [ PASS] "?foo/bar" decoded as ((foo/bar . #t)) ....................... [ PASS] ((foo/bar . #t)) encoded to "?foo/bar" ....................... [ PASS] "?foo%3Fbar" decoded as ((foo?bar . #t)) ..................... [ PASS] ((foo?bar . #t)) encoded to "?foo%3Fbar" ..................... [ PASS] "?foo%2Ebar" decoded as ((foo.bar . #t)) ..................... [ PASS] ((foo.bar . #t)) encoded to "?foo.bar" ....................... [ PASS] 14 tests completed in 0.001 seconds. 14 out of 14 (100%) tests passed. -- done testing query ----------------------------------------------- -- testing fragment -------------------------------------------------- "?foo" decoded as #f ......................................... [ PASS] #f encoded to "?foo" ......................................... [ PASS] "#bar" decoded as "bar" ...................................... [ PASS] "bar" encoded to "#bar" ...................................... [ PASS] "?foo#bar" decoded as "bar" .................................. [ PASS] "bar" encoded to "?foo#bar" .................................. [ PASS] "#foo?bar" decoded as "foo?bar" .............................. [ PASS] "foo?bar" encoded to "#foo?bar" .............................. [ PASS] "#foo%3Fbar" decoded as "foo?bar" ............................ [ PASS] "foo?bar" encoded to "#foo%3Fbar" ............................ [ PASS] "#foo/bar" decoded as "foo/bar" .............................. [ PASS] "foo/bar" encoded to "#foo/bar" .............................. [ PASS] "#foo%2Ebar" decoded as "foo.bar" ............................ [ PASS] "foo.bar" encoded to "#foo.bar" .............................. [ PASS] 14 tests completed in 0.002 seconds. 14 out of 14 (100%) tests passed. -- done testing fragment --------------------------------------------- 8 subgroups completed in 0.01 seconds. 8 out of 8 (100%) subgroups passed. -- done testing internal representations --------------------------------- -- testing updating ------------------------------------------------------ -- testing query ----------------------------------------------------- ((foo . "bar?qux")) -> "?foo=bar%3Fqux" ...................... [ PASS] ((foo?bar . "qux")) -> "?foo%3Fbar=qux" ...................... [ PASS] ((foo . "bar&qux")) -> "?foo=bar%26qux" ...................... [ PASS] ((foo&bar . "qux")) -> "?foo%26bar=qux" ...................... [ PASS] ((foo . "bar=qux")) -> "?foo=bar%3Dqux" ...................... [ PASS] ((foo=bar . "qux")) -> "?foo%3Dbar=qux" ...................... [ PASS] ((foo . "bar") (foo . "qux")) -> "?foo=bar;foo=qux" .......... [ PASS] 7 tests completed in 0.004 seconds. 7 out of 7 (100%) tests passed. -- done testing query ------------------------------------------------ -- testing port ------------------------------------------------------ 80 -> "http://a" ............................................. [ PASS] 8080 -> "http://a:8080" ...................................... [ PASS] 2 tests completed in 0.0 seconds. 2 out of 2 (100%) tests passed. -- done testing port ------------------------------------------------- -- testing scheme ---------------------------------------------------- http -> "http://a" ........................................... [ PASS] http -> "http://a" ........................................... [ PASS] http -> "http://a" ........................................... [ PASS] https -> "https://a" ......................................... [ PASS] 4 tests completed in 0.001 seconds. 4 out of 4 (100%) tests passed. -- done testing scheme ----------------------------------------------- 3 subgroups completed in 0.005 seconds. 3 out of 3 (100%) subgroups passed. -- done testing updating ------------------------------------------------- -- testing manual constructor -------------------------------------------- (scheme: http host: "example.com" port: 123 path: (/ "foo" "bar") query: ((a . "b") (c . "d")) fragment: "location") -> "http://example.com:123/foo/bar?a=b;c=d#location" [ PASS] (host: "example.com" port: 123 path: (/ "foo" "bar") query: ((a . "b") (c . "d")) fragment: "location") -> "//example.com:123/foo/bar?a=b;c=d#location" [ PASS] (port: 123 path: (/ "foo" "bar") query: ((a . "b") (c . "d")) fragment: "location") -> "/foo/bar?a=b;c=d#location" [ PASS] (path: ("foo" "bar") query: ((a . "b") (c . "d")) fragment: "location") -> "foo/bar?a=b;c=d#location" [ PASS] (path: (/ "") query: ((a . "b") (c . "d")) fragment: "location") -> "/?a=b;c=d#location" [ PASS] (query: ((a . "b") (c . "d")) fragment: "location") -> "?a=b;c=d#location" [ PASS] (fragment: "location") -> "#location" ............................ [ PASS] (host: "example.com" query: ((a . "b") (c . "d"))) -> "//example.com?a=b;c=d" [ PASS] (host: "example.com" fragment: "location") -> "//example.com#location" [ PASS] (path: (/ "")) -> "/" ............................................ [ PASS] (path: (/)) -> "/" ............................................... [ PASS] (path: ()) -> "" ................................................. [ PASS] () -> "" ......................................................... [ PASS] 13 tests completed in 0.004 seconds. 13 out of 13 (100%) tests passed. -- done testing manual constructor --------------------------------------- -- testing form-urlencoding-hoehrmann-draft-cases ------------------------ encode ((| a b c | . " 1 3 ")) -> "+a+b+c+=+1++3+" .............. [ PASS] decode "+a+b+c+=+1++3+" -> ((| a b c | . " 1 3 ")) .............. [ PASS] decode "%20a%20b%20c%20=%201%20%203%20" -> ((| a b c | . " 1 3 ")) [ PASS] decode " a b c = 1 3 " -> ((| a b c | . " 1 3 ")) .............. [ PASS] encode ((Text . "Line1\nLine2")) -> "Text=Line1%0ALine2" ......... [ PASS] decode "Text=Line1%0ALine2" -> ((Text . "Line1\nLine2")) ......... [ PASS] decode "Text=Line1\nLine2" -> ((Text . "Line1\nLine2")) .......... [ PASS] encode ((Cipher . "c=(m^e)%n")) -> "Cipher=c%3D%28m%5Ee%29%25n" .. [ PASS] decode "Cipher=c%3D%28m%5Ee%29%25n" -> ((Cipher . "c=(m^e)%n")) .. [ PASS] decode "Cipher=c=(m%5Ee)%25n" -> ((Cipher . "c=(m^e)%n")) ........ [ PASS] decode "Cipher=c=(m^e)%n" -> ((Cipher . "c=(m^e)%n")) ............ [ PASS] decode "%43%69%70%68%65%72=%63%3d%28%6D%5E%65%29%25%6e" -> ((Cipher . "c=(m^e)%n")) [ PASS] encode ((|| . #t) (|| . #t)) -> ";" .............................. [ PASS] decode ";" -> ((|| . #t) (|| . #t)) .............................. [ PASS] encode ((|| . #t) (|| . "")) -> ";=" ............................. [ PASS] decode ";=" -> ((|| . #t) (|| . "")) ............................. [ PASS] encode ((|| . "") (|| . #t)) -> "=;" ............................. [ PASS] decode "=;" -> ((|| . "") (|| . #t)) ............................. [ PASS] encode ((|| . "") (|| . "")) -> "=;=" ............................ [ PASS] decode "=;=" -> ((|| . "") (|| . "")) ............................ [ PASS] encode ((|| . "")) -> "=" ........................................ [ PASS] decode "=" -> ((|| . "")) ........................................ [ PASS] encode ((|| . #t)) -> "" ......................................... [ PASS] decode "" -> ((|| . #t)) ......................................... [ PASS] encode ((a&b . "1") (c . "2;3") (e . "4")) -> "a%26b=1;c=2%3B3;e=4" [ PASS] decode "a%26b=1;c=2%3B3;e=4" -> ((a&b . "1") (c . "2;3") (e . "4")) [ PASS] decode "a%26b=1&c=2%3B3&e=4" -> ((a&b . "1") (c . "2;3") (e . "4")) [ PASS] decode "a%26b=1;c=2%3B3&e=4" -> ((a&b . "1") (c . "2;3") (e . "4")) [ PASS] decode "a%26b=1&c=2%3B3;e=4" -> ((a&b . "1") (c . "2;3") (e . "4")) [ PASS] encode ((img . #t) (avail . #t) (name . #t) (price . #t)) -> "img;avail;name;price" [ PASS] decode "img;avail;name;price" -> ((img . #t) (avail . #t) (name . #t) (price . #t)) [ PASS] encode ((foo+bar . "mooh+qux") (|foo bar| . "mooh qux")) -> "foo%2Bbar=mooh%2Bqux;foo+bar=mooh+qux" [ PASS] decode "foo%2Bbar=mooh%2Bqux;foo+bar=mooh+qux" -> ((foo+bar . "mooh+qux") (|foo bar| . "mooh qux")) [ PASS] encode ((no+value . #t) (|no value| . #t)) -> "no%2Bvalue;no+value" [ PASS] decode "no%2Bvalue;no+value" -> ((no+value . #t) (|no value| . #t)) [ PASS] 35 tests completed in 0.007 seconds. 35 out of 35 (100%) tests passed. -- done testing form-urlencoding-hoehrmann-draft-cases ------------------- -- testing miscellaneous ------------------------------------------------- scheme doesn't reset port if port given .......................... [ PASS] separator string order is maintained in form-urlencode ........... [ PASS] False values can't be distinguished from missing values .......... [ PASS] 3 tests completed in 0.001 seconds. 3 out of 3 (100%) tests passed. -- done testing miscellaneous -------------------------------------------- 5 subgroups completed in 0.043 seconds. 5 out of 5 (100%) subgroups passed. -- done testing uri-common ---------------------------------------------------