about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--Test/V01zmodload.ztst6
2 files changed, 10 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index f5f8b1782..eeac6f242 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2001-09-28  Bart Schaefer  <schaefer@zsh.org>
+
+	* 15889: Test/V01zmodload.ztst: Compute module dependencies for
+	external modules so that they can be unloaded in the right order.
+
 2001-09-27  Oliver Kiddle  <opk@zsh.org>
 
 	* 15882: zshconfig.ac, Etc/MACHINES, Test/C02cond.ztst: fix
diff --git a/Test/V01zmodload.ztst b/Test/V01zmodload.ztst
index fef7d0232..3787024e1 100644
--- a/Test/V01zmodload.ztst
+++ b/Test/V01zmodload.ztst
@@ -12,6 +12,10 @@
    eval "$name $modfile $link $auto $load"
    [[ $link == no ]] && continue
    mods=($mods $name)
+   moddeps=
+   modfile=$ZTST_srcdir/../$modfile
+   eval ${${${(f)"$(<$modfile)"}[(r)moddeps=*]}:-:}
+   [[ -n $moddeps ]] && zmodload -d $name $=moddeps
  done < $ZTST_testdir/../config.modules
 
  zmodunload() {
@@ -157,5 +161,5 @@
 %clean
 
  eval "$deps"
- unset deps name modfile link auto load funcs mods
+ unset deps name modfile link auto load funcs mods moddeps
  unfunction zmodunload