# Commands covered:  sha1
#
# 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) 2000 by Scriptics Corporation.
#
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: sample.test,v 1.1 2002/03/06 05:35:31 hobbs Exp $

if {[lsearch [namespace children] ::tcltest] == -1} {
    package require tcltest
    namespace import ::tcltest::*
}

package require Tclsha1

test sha-1.1 {Use of -string operand} {
    set result [sha1 -string foo]
} {0beec7b5ea3f0fdbc95d0dd47f3c5bc275da8a33}

test sha-1.2 {Use of -init operand} {
    set result [catch {sha1 -init}]
} {0}


# cleanup
::tcltest::cleanupTests
return
