4 # test glob() in File::DosGlob
14 # override it in main::
15 use File::DosGlob 'glob';
17 # test if $_ takes as the default
20 print "not " if $_ ne 'op/a*.t';
22 print "# |@r|\nnot " if @r < 9;
25 # check if <*/*> works
27 # atleast {argv,abbrev,anydbm,autoloader,append,arith,array,assignwarn,auto}.t
28 print "not " if @r < 9;
32 # check if scalar context works
34 while (defined($_ = <*/a*.t>)) {
38 print "not " if @r != $r;
41 # check if list context works
47 print "not " if @r != $r;
50 # test if implicit assign to $_ in while() works
56 print "not " if @r != $r;
59 # test if explicit glob() gets assign magic too
61 while (glob '*/a*.t') {
65 print "not " if "@r" ne "@s";
68 # how about in a different package, like?
70 use File::DosGlob 'glob';
72 while (glob '*/a*.t') {
76 print "not " if "@r" ne "@s";
79 # test if different glob ops maintain independent contexts
91 print "not " if "@r" ne "@s";
94 # how about a global override, hm?
96 use File::DosGlob 'GLOBAL_glob';
103 while (glob '*/b*.t') {
109 print "not " if "@r" ne "@s";