Hi
I have a following function that i call from my main script in korn shell.
#Unset all functions from the cache
#/bin/ksh
#Unset all functions from the cache
init () {
for func in "$(ls)"
do
echo "$func"
unset -f $func
if [$? -ne 0] ; then
return 1
fi
done
}
I want to know how to unit test this functions individually ?
As my main function just calls many functions like this.
if i go to directory and run init all by itself on command line i get
ksh[4]: unset: 0403-008 The number of parameters specified is not correct.
Any ideas on what i am doing wrong