diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2006-12-11 18:33:21 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2006-12-11 18:33:21 +0000 |
commit | 7cda84c25edae6d45a3e8e620b4c559e7a71899b (patch) | |
tree | 4254c8b74f644c2a1ae9cec43c24138272db71f1 /lib | |
parent | 78d0cf80609ca6ef7050cc76fbcfe7807885b9ce (diff) | |
download | perl-7cda84c25edae6d45a3e8e620b4c559e7a71899b.tar.gz |
Don't load the Win32 module on non-win32 platforms
p4raw-id: //depot/perl@29519
Diffstat (limited to 'lib')
-rwxr-xr-x | lib/File/CheckTree.t | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/File/CheckTree.t b/lib/File/CheckTree.t index 60f1a425ab..e4491d413b 100755 --- a/lib/File/CheckTree.t +++ b/lib/File/CheckTree.t @@ -11,10 +11,15 @@ BEGIN { plan tests => 6 } use strict; +BEGIN { # Cwd::cwd does an implicit "require Win32", but # the ../lib directory in @INC will no longer work once # we chdir() out of the "t" directory. -use Win32; + if ($^O eq 'MSWin32') { + require Win32; + Win32->import(); + } +} use File::CheckTree; use File::Spec; # used to get absolute paths |