if {[lsearch [namespace children] ::tcltest] == -1} {
    package require tcltest
    namespace import ::tcltest::*
}
set dirname [file dirname [info script]]
source      [file join $dirname uri.tcl]
package require uri

test uri-rfc2396-1.1 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q g:h]
} g:h

test uri-rfc2396-1.2 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q g]
} http://a/b/c/g

test uri-rfc2396-1.3 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q ./g]
} http://a/b/c/g

test uri-rfc2396-1.4 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q g/]
} http://a/b/c/g/

test uri-rfc2396-1.5 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q /g]
} http://a/g

test uri-rfc2396-1.6 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q //g]
} http://g

test uri-rfc2396-1.7 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q ?y]
} http://a/b/c/?y

test uri-rfc2396-1.8 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q g?y]
} http://a/b/c/g?y

test uri-rfc2396-1.9 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q \#s]
} {(current document)\#s}

test uri-rfc2396-1.10 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q g\#s]
} http://a/b/c/g\#s

test uri-rfc2396-1.11 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q g?y\#s]
} http://a/b/c/g?y\#s

test uri-rfc2396-1.12 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q \;x]
} http://a/b/c/\;x

test uri-rfc2396-1.13 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q g\;x]
} http://a/b/c/g\;x

test uri-rfc2396-1.14 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q g\;x?y#s]
} http://a/b/c/g\;x?y#s

test uri-rfc2396-1.15 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q .]
} http://a/b/c/

test uri-rfc2396-1.16 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q ./]
} http://a/b/c/

test uri-rfc2396-1.17 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q ..]
} http://a/b/

test uri-rfc2396-1.18 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q ../]
} http://a/b/

test uri-rfc2396-1.19 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q ../g]
} http://a/b/g

test uri-rfc2396-1.20 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q ../..]
} http://a/

test uri-rfc2396-1.21 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q ../../]
} http://a/

test uri-rfc2396-1.22 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p?q ../../g]
} http://a/g


test uri-rfc2396-2.1 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p g:h]
} g:h

test uri-rfc2396-2.2 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p g]
} http://a/b/c/g

test uri-rfc2396-2.3 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p ./g]
} http://a/b/c/g

test uri-rfc2396-2.4 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p g/]
} http://a/b/c/g/

test uri-rfc2396-2.5 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p /g]
} http://a/g

test uri-rfc2396-2.6 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p //g]
} http://g

test uri-rfc2396-2.7 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p ?y]
} http://a/b/c/?y

test uri-rfc2396-2.8 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p g?y]
} http://a/b/c/g?y

test uri-rfc2396-2.9 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p \#s]
} {(current document)\#s}

test uri-rfc2396-2.10 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p g\#s]
} http://a/b/c/g\#s

test uri-rfc2396-2.11 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p g?y\#s]
} http://a/b/c/g?y\#s

test uri-rfc2396-2.12 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p \;x]
} http://a/b/c/\;x

test uri-rfc2396-2.13 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p g\;x]
} http://a/b/c/g\;x

test uri-rfc2396-2.14 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p g\;x?y#s]
} http://a/b/c/g\;x?y#s

test uri-rfc2396-2.15 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p .]
} http://a/b/c/

test uri-rfc2396-2.16 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p ./]
} http://a/b/c/

test uri-rfc2396-2.17 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p ..]
} http://a/b/

test uri-rfc2396-2.18 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p ../]
} http://a/b/

test uri-rfc2396-2.19 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p ../g]
} http://a/b/g

test uri-rfc2396-2.20 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p ../..]
} http://a/

test uri-rfc2396-2.21 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p ../../]
} http://a/

test uri-rfc2396-2.22 {uri::resolve} {knownBug sf-tcllib-bug-581781} {
    uri::canonicalize [uri::resolve http://a/b/c/d\;p ../../g]
} http://a/g


#test uri-rfc2396-2. {uri::resolve} {knownBug sf-tcllib-bug-581781} {
#    uri::resolve http://a/b/c/d\;p 
#} 

# -------------------------------------------------------------------------

::tcltest::cleanupTests
return

# -------------------------------------------------------------------------
# Local Variables:
#   mode: tcl
#   indent-tabs-mode: nil
# End:
