Skip to content
Tcl Source Code Artifact [af675fad46]
Login

Artifact [af675fad46]

Artifact af675fad46741531986e916c45e95174f8018031:


# The file tests the tclZlib.c file.
#
# This file contains a collection of tests for one or more of the Tcl built-in
# commands. Sourcing this file into Tcl runs the tests and generates output
# for errors. No output means no errors were found.
#
# Copyright (c) 1996-1998 by Sun Microsystems, Inc.
# Copyright (c) 1998-1999 by Scriptics Corporation.
#
# See the file "license.terms" for information on usage and redistribution of
# this file, and for a DISCLAIMER OF ALL WARRANTIES.

if {"::tcltest" ni [namespace children]} {
    package require tcltest 2.1
    namespace import -force ::tcltest::*
}

testConstraint zlib [llength [info commands zlib]]

test zipfs-1.1 {zipfs basics} -constraints zlib -body {
    load {} zipfs
    package require zipfs
} -result {1.0}

test zipfs-1.2 {zipfs basics} -constraints zlib -returnCodes error -body {
    ::zipfs::mount a b c d e f
} -result {wrong # args: should be "::zipfs::mount ?zipfile ?mountpoint? ?password???"}

test zipfs-1.3 {zipfs basics} -constraints zlib -returnCodes error -body {
    ::zipfs::unmount a b c d e f
} -result {wrong # args: should be "::zipfs::unmount zipfile"}

test zipfs-1.4 {zipfs basics} -constraints zlib -returnCodes error -body {
    ::zipfs::mkkey a b c d e f
} -result {wrong # args: should be "::zipfs::mkkey password"}

test zipfs-1.5 {zipfs basics} -constraints zlib -returnCodes error -body {
    ::zipfs::mkimg a b c d e f
} -result {wrong # args: should be "::zipfs::mkimg outfile indir ?strip? ?password? ?infile?"}

test zipfs-1.6 {zipfs basics} -constraints zlib -returnCodes error -body {
    ::zipfs::mkzip a b c d e f
} -result {wrong # args: should be "::zipfs::mkzip outfile indir ?strip? ?password?"}

test zipfs-1.7 {zipfs basics} -constraints zlib -returnCodes error -body {
    ::zipfs::exists a b c d e f
} -result {wrong # args: should be "::zipfs::exists filename"}

test zipfs-1.8 {zipfs basics} -constraints zlib -returnCodes error -body {
    ::zipfs::info a b c d e f
} -result {wrong # args: should be "::zipfs::info filename"}

test zipfs-1.9 {zipfs basics} -constraints zlib -returnCodes error -body {
    ::zipfs::list a b c d e f
} -result {wrong # args: should be "::zipfs::list ?(-glob|-regexp)? ?pattern?"}






::tcltest::cleanupTests
return

# Local Variables:
# mode: tcl
# End: