diff options
author | patthoyts <patthoyts@users.sourceforge.net> | 2005-11-03 00:17:30 (GMT) |
---|---|---|
committer | patthoyts <patthoyts@users.sourceforge.net> | 2005-11-03 00:17:30 (GMT) |
commit | 2ac3a08a98a293de62ed6ae01aa7a7d139660207 (patch) | |
tree | 86fab92b7dc7b1f3c9f8d9b9a0ead95a215fd1cd /tests/env.test | |
parent | 4299352915cf05025553108f48b7bf58f48a8353 (diff) | |
download | tcl-2ac3a08a98a293de62ed6ae01aa7a7d139660207.zip tcl-2ac3a08a98a293de62ed6ae01aa7a7d139660207.tar.gz tcl-2ac3a08a98a293de62ed6ae01aa7a7d139660207.tar.bz2 |
Applied patch #1096916 to support building with MSVC 8.
* generic/regerror.c: Avoid use of reserved word.
* generic/tcl.h: Select the right Tcl_Stat structure
* generic/tclDate.c: Casts to handle 64 bit time_t case.
* tests/env.test: Include essential envvar on Win32
* win/nmakehlp.c: Handle new return codes.
* win/makefile.vc: Use the selected options.
* win/rules.vc: Check options are applicable
* win/tclWinPort.h: Disable deprecated function warnings
* win/tclWinSock.c: Provide default value to avoid warning.
* win/tclWinTime.c: Add casts to handle 64bit time_t type.
Diffstat (limited to 'tests/env.test')
-rw-r--r-- | tests/env.test | 17 |
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 } {} |