summaryrefslogtreecommitdiffstats
path: root/tests/env.test
diff options
context:
space:
mode:
Diffstat (limited to 'tests/env.test')
-rw-r--r--tests/env.test17
1 files changed, 13 insertions, 4 deletions
diff --git a/tests/env.test b/tests/env.test
index c2bad61..a1e50d9 100644
--- a/tests/env.test
+++ b/tests/env.test
@@ -11,7 +11,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: env.test,v 1.22 2005/10/05 08:03:35 hobbs Exp $
+# RCS: @(#) $Id: env.test,v 1.23 2005/11/03 00:17:31 patthoyts Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest 2
@@ -76,7 +76,11 @@ set printenvScript [makeFile {
lrem names ComSpec
lrem names ""
}
- foreach name {TCL_LIBRARY PATH LD_LIBRARY_PATH LIBPATH PURE_PROG_NAME DISPLAY SHLIB_PATH DYLD_LIBRARY_PATH DYLD_FRAMEWORK_PATH __CF_USER_TEXT_ENCODING } {
+ foreach name {
+ TCL_LIBRARY PATH LD_LIBRARY_PATH LIBPATH PURE_PROG_NAME DISPLAY
+ SHLIB_PATH DYLD_LIBRARY_PATH DYLD_FRAMEWORK_PATH
+ __CF_USER_TEXT_ENCODING SYSTEMDRIVE SYSTEMROOT
+ } {
lrem names $name
}
foreach p $names {
@@ -99,19 +103,24 @@ proc getenv {} {
# Save the current environment variables at the start of the test.
foreach name [array names env] {
- set env2($name) $env($name)
+ set env2([string toupper $name]) $env($name)
unset env($name)
}
# Added the following lines so that child tcltest can actually find its
# library if the initial tcltest is run from a non-standard place.
# ('saved' env vars)
-foreach name {TCL_LIBRARY PATH LD_LIBRARY_PATH LIBPATH DISPLAY SHLIB_PATH DYLD_LIBRARY_PATH DYLD_FRAMEWORK_PATH} {
+foreach name {
+ TCL_LIBRARY PATH LD_LIBRARY_PATH LIBPATH DISPLAY SHLIB_PATH
+ DYLD_LIBRARY_PATH DYLD_FRAMEWORK_PATH SYSTEMDRIVE SYSTEMROOT
+} {
if {[info exists env2($name)]} {
set env($name) $env2($name);
}
}
+#array set env [array get env2 S*]
+
test env-2.1 {adding environment variables} {exec} {
getenv
} {}