Something went wrong. Try again.
Reactos
Something went wrong. Try again.
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694@pwd@>echo Tests for cmd's builtin commands@space@Tests for cmd's builtin commands@pwd@>echo ------------ Testing 'echo' [ON] ------------@space@------------ Testing 'echo' [ON] ------------@pwd@>echo word@space@word@pwd@>echo 'singlequotedword'@space@'singlequotedword'@pwd@>echo "doublequotedword"@space@"doublequotedword"at-echoed-word@pwd@>echo "/?"@space@"/?"@pwd@>echo.@pwd@>echo .@space@.@pwd@>echo.wordword@pwd@>echo .word@space@.word@pwd@>echo:@pwd@>echo :@space@:@pwd@>echo:wordword@pwd@>echo :word@space@:word@pwd@>echo/@pwd@>echo /@space@/@pwd@>echo/wordword@pwd@>echo /word@space@/word@pwd@>echo off now@space@off now@pwd@>echo word@space@@space@word@space@@pwd@>echo word@space@@space@@space@word@space@@space@@pwd@>echo word@space@word@pwd@>echo@tab@word@space@word@pwd@>echo@tab@word@space@@tab@@space@word@space@@tab@@pwd@>echo@tab@word@tab@@space@@space@word@tab@@space@@pwd@>echo word@space@word@pwd@>echo@space@@tab@word@space@@tab@word@pwd@>echo@space@@space@@tab@word@space@@space@@tab@word@pwd@>echo@tab@@tab@word@space@@tab@word@pwd@>echo @tab@ on @space@@space@--- @ with chains and brackets@todo_wine@@pwd@>(echo the @ character chains until && ) && echo and can hide brackets || () ||@space@@todo_wine@the @ character chains until@todo_wine@we leave the current depth@todo_wine@and can hide brackets@todo_wine@---noecho1noecho2echo3------------ Testing 'echo' [OFF] ------------word'singlequotedword'"doublequotedword"at-echoed-word"/?".word.word:word:word/word/wordon againword@space@word@space@@space@wordwordword@space@@tab@word@tab@@space@word@tab@word@space@@tab@word@tab@word------------ Testing mixed echo modes ------------@echo onif 1==1 echo fooif 1==1 @echo bar@echo offif 1==1 echo foo2if 1==1 @echo bar2@todo_wine@@pwd@>if 1 == 1 echo foo@space@foo@todo_wine@@pwd@>if 1 == 1@space@barfoo2bar2------------ Testing parameterization ------------'a', 'b', 'c''"a b c"', '', '''"a b"\c', '', '''a', '~`+', '.{}!+b''a', 'b', '''"a;b"', '', '''a', 'b', '''a[b]{c}(d)e', '', '''a', '', ''second line'a', 'b', 'c''a', 'b', 'c''a', 'b', ''------------ Testing rem ------------@pwd@>rem Hello@space@@pwd@>rem Hello@space@@pwd@>rem Hello || foo@space@@pwd@>rem echo lol@space@@pwd@>rem echo foo & echo bar@space@@pwd@>rem @tab@ Hello@space@@pwd@>rem@tab@ Hello@space@@pwd@>rem@tab@echo foo & echo bar@space@------------ Testing redirection operators --------------- stdout redirectionfoofoo@space@foo@tab@foo@space@foo@tab@foo7@space@@or_broken@foo@tab@foo9@space@@or_broken@foo@tab@foo1foo11foo12foo13foo14foo15--- stdout appendingfoofoo@space@foob@space@foob@space@fooc@space@foob@space@fooc@space@food1foob@space@fooc@space@food1food2food21@todo_wine@foo7@space@@space@@or_broken@not supported@space@@todo_wine@foo@or_broken@not supported--- redirections within IF statementsfoo1foo2-----foo2foo3file does not exist, okfoo4baz5baz6@space@baz7baz8bazfoo@space@bazfooABC------------ Testing circumflex escape character ------------hello, worldhello, worldhell^o, worldhell^o, worldhelloworldhelloworldhellofinishedbazbazfoo | echo barfoo & echo barbak &baz@space@0@or_broken@1foo > foo<ffoofWINE_FOO=bar | baz0WINE_FOO=bar ^| bazbar | baz0------------ Testing chains --------------- chain successa1a2b1b2c1@todo_wine@---d1d2d3e1e2e3f1f2@todo_wine@---g1g2g3h1h2h3i1i2@todo_wine@---j1@todo_wine@j3@todo_wine@---k1@todo_wine@---l1@todo_wine@------ chain failurea1a2b1@todo_wine@---c1c2d1d2d3e1e2@todo_wine@---f1f2f3g1@todo_wine@g3@todo_wine@---h1@todo_wine@---i1@todo_wine@i3@todo_wine@---j1j2j3k1k2@todo_wine@---l1l2l3--- chain bracketsa1a2a3b1b2b3c1c2@todo_wine@---d1d2d3e1e2e3f1f2@todo_wine@---g1@todo_wine@---h1@todo_wine@---i1@todo_wine@---j1j2j3k1k2@todo_wine@---l1l2l3m1@todo_wine@---n1@todo_wine@---o1@todo_wine@---p1p2p3q1q2@todo_wine@---r1r2r3--- chain pipe@todo_wine@a@space@@todo_wine@a@space@---b2c1c3d1@todo_wine@---e1e3f2f3g2@todo_wine@---h2h3i3--- chain pipe inputa2:[a1,a2]b3:[b2:[b1,b2],b3]@or_broken@b3:[b2:,b3]c4:[c3:[c2:[c1,c2],c3],c4]@or_broken@c4:[c3:[c2:,c3],c4]@or_broken@c4:[c3:,c4]d2:[d1,d2]e3:[e2:[e1,e2],e3]@or_broken@e3:[e2:,e3]f4:[f3:[f2:[f1,f2],f3],f4]@or_broken@f4:[f3:[f2:,f3],f4]@or_broken@f4:[f3:,f4]--- chain elsea1b2@todo_wine@---@todo_wine@c3@todo_wine@---@todo_wine@d3@todo_wine@---@todo_wine@---@todo_wine@---@todo_wine@---@todo_wine@------ chain else (if true)a1 else echo a2b2 else echo b3c1c2 else echo c3d1@todo_wine@---e1e2 else echo e3f3g1 else echo g2g3h1 else echo h2@todo_wine@---i1 else echo i2i3@todo_wine@j2@space@@todo_wine@---k1k2l1@todo_wine@---m1m2n1o1p1q1@todo_wine@------ chain else (if false)j3---k3l3m3n3o2o3p2@todo_wine@---q2q3------------ Testing 'set' ------------10WINE_FOOBAR not defined bazWINE_FOOBAR = baz0 baz20 barWINE_FOOBAR= barWINE_FOOBAR = baz2WINE_FOOBAR = baz2WINE_FOOBAR not defined1barfoobarWINE_FOO not definedWINE_BAZ=bazbazbazbazset "WINE_FOO=bar" should not include the quotes in the variable valuebarfoo'''foo@space@''foo@tab@''value@space@''value''jim fred''"jim" fred''jim fred''jim''apple"banana"grape'I'm here!@space@I'm here!@space@I'm here!@space@------------ Testing 'choice' ------------@todo_wine@Example message [A,B,C]?A@or_broken@choice unavailable@todo_wine@1@or_broken@9009@todo_wine@Example message [A,B,C]?B@or_broken@choice unavailable@todo_wine@2@or_broken@9009@todo_wine@[D,E,F]?F@or_broken@choice unavailable@todo_wine@3@or_broken@9009@todo_wine@[A,B,C,X,Y,Z]?Y@or_broken@choice unavailable@todo_wine@5@or_broken@9009@todo_wine@A@or_broken@choice unavailable@todo_wine@1@or_broken@9009@todo_wine@[a,b,c,A,B,C]?A@or_broken@choice unavailable@todo_wine@4@or_broken@9009@todo_wine@255@or_broken@9009------------ Testing variable expansion ------------~p0 should be path containing batch file@path@@path@~dp0 should be directory containing batch file@drive@@path@@drive@@path@CD value @pwd@@or_broken@CD value@space@%PPSPPSERRORLEVEL0000ERRORLEVEL00%P00SP0S------------ Testing variable substrings ------------qqweer'ty'@or_broken@'''t'@or_broken@''ert@or_broken@qwertye@or_broken@qwerty''@or_broken@'qwerty'r@or_broken@qwerty------------ Testing variable substitution --------------- in FOR variables"A B"C"A B"C'A B'@or_broken@'''C'@or_broken@''@drive@@path@C D@or_broken@%~ff@drive@@path@E@or_broken@%~ff@drive@@drive@@path@@or_broken@%~pd@path@@or_broken@%~pdL MN'.OOL''.TABC''''@drive@@shortpath@R S'@or_broken@'''@drive@@shortpath@T'@or_broken@'''@drive@@shortpath@ABCDEFGHIJK.LMNOP'@or_broken@''''@or_broken@'%~ai'''@or_broken@'%~ai''--a------'@or_broken@'--a--------'@or_broken@'--a--c---'@or_broken@'%~ai''5'@or_broken@'%~zi'''@or_broken@'%~ti'''@or_broken@'%~ti'''@or_broken@'%~zi'''@or_broken@'%~zi'@drive@@path@@drive@@path@@drive@@drive@@drive@@drive@'''.eh'',,,,,,,,,'--- in parameters"A B"C'A B'@or_broken@'''C'@or_broken@''@drive@@path@C D@drive@@path@E@drive@@drive@@path@@path@L MN'.OOL''.TABC''''@drive@@shortpath@R S'@or_broken@'''@drive@@shortpath@T'@or_broken@'''@drive@@shortpath@ABCDEFGHIJK.LMNOP'@or_broken@''@drive@@path@@drive@@path@@drive@@drive@@drive@@drive@'''.eh'@or_broken@''------------ Testing parameter zero ------------:func parm1[:func] [@drive@] [@path@] [test] [.cmd] [@drive@@shortpath@test.cmd]------------ Testing variable delayed expansion --------------- default mode (load-time expansion)foo!WINE_FOO!foofoo--- runtime (delayed) expansion modefoofoo@or_broken@!WINE_FOO!foobar@or_broken@foo00@or_broken@1foo!WINE_FOO!--- using /V cmd flagfoofoo@or_broken@!WINE_FOO!foo!WINE_FOO!------------ Testing conditional execution --------------- unconditional ampersandfoo1bar2@space@foo2foobar deleted--- on success conditional and@todo_wine@foo3 not createdbar4@space@foo4--- on failure conditional orfoo5foo6@space@@todo_wine@------------ Testing cd ------------singleFileCurrent dir: @drive@@path@foobar@or_broken@Current dir:@space@@drive@@path@foobar@pwd@@drive@@path@foobar@pwd@@drive@@path@foobar@pwd@@pwd@@pwd@@drive@@path@foobar\bar bak@drive@@path@foobar\bar bak@drive@@path@foobar\bar bak@drive@@path@foobar\bar bak@drive@@path@foobar\bar bak@pwd@@drive@@path@foobar------------ Testing type ------------@pwd@>type foobaz@space@bar@pwd@>echo ---@space@---bar---1bar---2bar---3---4---5barfoo---6foobazfoobay---7------------ Testing NUL ------------barbarbarNULfoo createdPassed: file size check on a.a [7]@or_broken@Skipping file size check on NT4Passed: file size check on b.b [8]@or_broken@Skipping file size check on NT4Passed: file size check on a.a [7]@or_broken@Skipping file size check on NT4Passed: file size check on b.b [8]@or_broken@Skipping file size check on NT4Passed: file size check on a.a [7]@or_broken@Skipping file size check on NT4Passed: file size check on subdir\a.a [8]@or_broken@Skipping file size check on NT4------------ Testing if/else --------------- if/else should work with blocksif seems to workelse seems to workif seems not to detect /c as parameterelse if seems to workelse if seems to workelse if seems to workexpected1expected post-embedded ifcomparison operators surrounded by brackets seem to workcomparison operators surrounded by brackets seem to workcomparison operators surrounded by brackets seem to workcomparison operators surrounded by brackets seem to workwindir is definedwindir does exist--- case sensitivity with and without /i optionif seems to default to case sensitivityif /i seems to workif /I seems to work--- string comparisonsequalnon equalnon equalequal--- tabs handlingdoomdoomdoomlolquakequakequake--- comparison operators------ for stringsLSS string can be used as operand for LSS comparisonfloats are handled as stringsnumbers in quotes are handled as stringsnegative numbers as well@or_broken@NT4if /i seems to work for LSSA LSS BA LSS ABA LSS BAA LSS AAB LSS BAAB LSS BAB LSS BAAA LSS BAA LSS ABAA LSS BAb LSS B@or_broken@NT4a LSS B@or_broken@NT4a LSS B insensitiveA LSS bA LSS b insensitiveA LEQ AA LEQ BA LEQ ABA LEQ BAA LEQ AAB LEQ BB LEQ BAAB LEQ BAB LEQ ABAB LEQ BABA LEQ BAAA LEQ BAA LEQ ABAA LEQ BAAA LEQ AAb LEQ B@or_broken@NT4b LEQ B insensitivea LEQ B@or_broken@NT4a LEQ B insensitiveA LEQ bA LEQ b insensitiveA EQU AB EQU BAB EQU ABBA EQU BAAA EQU AAA EQU a insensitiveA NEQ BA NEQ ABA NEQ BAA NEQ AAB NEQ AB NEQ ABB NEQ BAB NEQ AAAB NEQ AAB NEQ BAB NEQ BAAB NEQ AABA NEQ ABA NEQ BBA NEQ ABBA NEQ AAAA NEQ AAA NEQ BAA NEQ ABAA NEQ BAA GEQ AB GEQ AB GEQ BB GEQ ABB GEQ AAAB GEQ AAB GEQ ABAB GEQ AABA GEQ ABA GEQ BBA GEQ ABBA GEQ BABA GEQ AAAA GEQ AAA GEQ AAB GTR AB GTR ABB GTR AAAB GTR AAB GTR AABA GTR ABA GTR BBA GTR ABBA GTR AAAA GTR A------------ Testing if/exist ------------exist explicit worksexist explicit unknown file worksexist explicit in subdir worksexist simple wildcard worksexist wildcard worksnegate exist wildcard worksexist wildcard bad subdir broken worksexist subdir okexist subdir with . okexist subdir with \ okexist subdir with \ and quotes ok------ for numbersnegative numbers handlednegative numbers handledoctal handledalso in negative formhexa handledalso in negative form11 LSS 1010 LSS 10 LSS 100 LSS 91 LSS 101 LSS 99 LSS 100 LEQ 00 LEQ 10 LEQ 100 LEQ 91 LEQ 11 LEQ 101 LEQ 910 LEQ 109 LEQ 109 LEQ 90 EQU 01 EQU 110 EQU 109 EQU 9octal okhexa okstring/hexa compare okstring/hexa compare ok0 NEQ 10 NEQ 100 NEQ 91 NEQ 01 NEQ 101 NEQ 910 NEQ 010 NEQ 110 NEQ 99 NEQ 09 NEQ 19 NEQ 100 GEQ 01 GEQ 01 GEQ 110 GEQ 010 GEQ 110 GEQ 1010 GEQ 99 GEQ 09 GEQ 19 GEQ 91 GTR 010 GTR 010 GTR 110 GTR 99 GTR 09 GTR 1------ for numbers and stringified numbersstrings and integers not equalstrings and integers not equalfoo"10" GEQ "1"'1' GEQ 1@or_broken@NT41 GEQ "1""1" GEQ "1"'1' GEQ "1""10" GEQ "1"non NT4@or_broken@1 GEQ '1''1' GEQ '1'foo1 GEQ "10"foo'1' GEQ "10""10" GEQ "10"--- unconditional ampersand after if one line1@space@2@space@3 else echo 4---x@space@---x@space@---x@space@---x@space@--------------- Testing for --------------- plain FORABC%I%I%I%j%j%jABC141ABCXX2X3fooMXMNO`echoAB`'echoAB'"echo A B""A B"C--- imbricated FORsX YX YA CA DB CB DA CA DB CB D--- basic wildcardsbazbaz--- wildcards in subdirspop\bar1@space@pop\bar2.txt@space@pop\bar3@space@--- for /dbaz@space@foo@space@bar@space@PASSEDxxx - Should be xxxExpected second line--- for /RPlain directory enumerationPlain directory enumeration from provided rootFile enumerationFile enumeration from provided rootMixed enumerationMixed enumeration from provided rootWith duplicates enumerationStrip missing wildcards, keep unwildcarded namesfor /R passed--- Complex wildcards unix and windows slashWindows slashes, valid pathASIS: foobar\baz\bazbazWC : foobar\baz\bazbazWindows slashes, invalid pathASIS: foobar\jim\bazbazUnix slashes, valid pathASIS: foobar/baz/bazbazWC : bazbazUnix slashes, invalid pathASIS: foobar/jim/bazbazDone--- for /L135135021-1ErrorLevel 0ErrorLevel 0123413432142011-1-113--- rems inside for loops--- ifs inside for loopsa1b1d1a2b2d2a3c3d3a4c4d4--- set /a------ individual operationsWINE_foo correctly 3WINE_foo correctly -1WINE_foo correctly 3WINE_foo correctly 6WINE_foo correctly 10WINE_foo correctly 4WINE_foo correctly 4WINE_foo correctly -4WINE_foo correctly 0WINE_foo correctly 2WINE_foo correctly 2WINE_foo correctly -2WINE_foo correctly 1WINE_foo correctly 4WINE_foo correctly 0@or_broken@ERROR: WINE_foo incorrectly 1073741824 [0]WINE_foo correctly 0@or_broken@ERROR: WINE_foo incorrectly -1073741824 [0]WINE_foo correctly -4WINE_foo correctly 9WINE_foo correctly 2WINE_foo correctly 0WINE_foo correctly -1WINE_foo correctly -3WINE_foo correctly 0WINE_foo correctly 1WINE_foo correctly 1WINE_foo correctly 4WINE_foo correctly 1WINE_foo correctly 5WINE_foo correctly 5WINE_foo correctly 7WINE_foo correctly 5WINE_foo correctly 5WINE_foo correctly 5WINE_foo correctly 4WINE_foo correctly 6WINE_foo correctly 1WINE_foo correctly 4------ precedence and groupingWINE_foo correctly 10WINE_foo correctly 18@or_broken@ERROR: WINE_foo incorrectly [18]WINE_foo correctly 2@or_broken@ERROR: WINE_foo incorrectly 0 [2]WINE_foo correctly 2@or_broken@ERROR: WINE_foo incorrectly [2]WINE_foo correctly 0@or_broken@ERROR: WINE_foo incorrectly 4 [0]WINE_foo correctly 4@or_broken@ERROR: WINE_foo incorrectly [4]WINE_foo correctly 3@or_broken@ERROR: WINE_foo incorrectly [3]WINE_foo correctly 3@or_broken@ERROR: WINE_foo incorrectly [3]------ octal and hexadecimalWINE_foo correctly 18WINE_foo correctly 18WINE_foo correctly 15WINE_foo correctly 3------ variablesWINE_foo correctly 3@or_broken@ERROR: WINE_foo incorrectly 0 [3]WINE_bar correctly 3@or_broken@ERROR: WINE_bar incorrectly [3]WINE_foo correctly 3@or_broken@ERROR: WINE_foo incorrectly 0 [3]WINE_bar correctly 4@or_broken@ERROR: WINE_bar incorrectly [4]WINE_foo correctly 3@or_broken@ERROR: WINE_foo incorrectly 0 [3]WINE_bar correctly 3@or_broken@ERROR: WINE_bar incorrectly [3]WINE_baz correctly 4@or_broken@ERROR: WINE_baz incorrectly [4]WINE_foo correctly 9@or_broken@ERROR: WINE_foo incorrectly 3 [9]WINE_bar correctly 9@or_broken@ERROR: WINE_bar incorrectly 3 [9]WINE_foo correctly 0WINE_foo correctly 4WINE_bar correctly 4WINE_foo correctly -7@or_broken@ERROR: WINE_foo incorrectly 4 [-7]WINE_bar correctly -7@or_broken@ERROR: WINE_bar incorrectly 4 [-7]WINE_foo correctly -1@or_broken@ERROR: WINE_foo incorrectly -7 [-1]WINE_bar correctly -1@or_broken@ERROR: WINE_bar incorrectly -7 [-1]WINE_foo correctly 5@or_broken@ERROR: WINE_foo incorrectly 0 [5]WINE_bar correctly 1@or_broken@ERROR: WINE_bar incorrectly [1]WINE_foo correctly 4@or_broken@ERROR: WINE_foo incorrectly 1 [4]WINE_bar correctly 4@or_broken@ERROR: WINE_bar incorrectly 1 [4]WINE_foo correctly 1@or_broken@ERROR: WINE_foo incorrectly 4 [1]WINE_bar correctly 1@or_broken@ERROR: WINE_bar incorrectly 4 [1]WINE_foo correctly 0@or_broken@ERROR: WINE_foo incorrectly 1 [0]WINE_bar correctly 0@or_broken@ERROR: WINE_bar incorrectly 1 [0]WINE_foo correctly 5@or_broken@ERROR: WINE_foo incorrectly 0 [5]WINE_bar correctly 7@or_broken@ERROR: WINE_bar incorrectly [7]WINE_foo correctly 5@or_broken@ERROR: WINE_foo incorrectly 0 [5]WINE_bar correctly 7@or_broken@ERROR: WINE_bar incorrectly [7]WINE_foo correctly 19@or_broken@ERROR: WINE_foo incorrectly 0 [19]WINE_bar correctly 3@or_broken@ERROR: WINE_bar incorrectly [3]WINE_baz correctly 4--- quotesWINE_foo correctly 1WINE_foo correctly 1WINE_foo correctly 1WINE_bar correctly 2WINE_foo correctly 1WINE_bar correctly 2WINE_foo correctly 1WINE_bar correctly 2WINE_foo correctly 1WINE_bar correctly 2WINE_foo correctly 1WINE_bar correctly 2WINE_baz correctly 3WINE_foo correctly 1WINE_bar correctly 2WINE_baz correctly 3WINE_foo correctly 1WINE_bar correctly 2WINE_baz correctly 3WINE_foo correctly 1WINE_bar correctly 2WINE_baz correctly 3WINE_foo correctly 1WINE_bar correctly 2WINE_baz correctly 3WINE_foo correctly 1WINE_foo correctly 1WINE_bar correctly 5WINE_baz correctly 2WINE_foo correctly 18WINE_foo correctly 3WINE_bar correctly 7@or_broken@ERROR: WINE_bar incorrectly 4 [7]--- whitespace are ignored between double char operatorsWINE_foo correctly 10@or_broken@ERROR: WINE_foo incorrectly 4 [10]WINE_bar correctly 50@or_broken@ERROR: WINE_bar incorrectly 5 [50]WINE_foo correctly 772@or_broken@ERROR: WINE_foo incorrectly 4 [772]WINE_bar correctly 7720@or_broken@ERROR: WINE_bar incorrectly 5 [7720]--- invalid operator sequence44----- negative prefixWINE_foo correctly -1WINE_foo correctly 1@or_broken@ERROR: WINE_foo incorrectly [1]WINE_foo correctly 6WINE_foo correctly 0WINE_foo correctly 6WINE_foo correctly 2WINE_foo correctly 0@or_broken@ERROR: WINE_foo incorrectly [0]WINE_foo correctly 5WINE_foo correctly 3@or_broken@ERROR: WINE_foo incorrectly -5 [3]----- assignment tests involving the end destinationWINE_foo correctly 11@or_broken@ERROR: WINE_foo incorrectly 3 [11]WINE_foo correctly 6@or_broken@ERROR: WINE_foo incorrectly 2 [6]WINE_bar correctly 9@or_broken@ERROR: WINE_bar incorrectly [9]WINE_foo correctly 6@or_broken@ERROR: WINE_foo incorrectly 2 [6]WINE_bar correctly 10@or_broken@ERROR: WINE_bar incorrectly [10]WINE_baz correctly 7@or_broken@ERROR: WINE_baz incorrectly [7]WINE_foo correctly 7@or_broken@ERROR: WINE_foo incorrectly 2 [7]WINE_bar correctly 7@or_broken@ERROR: WINE_bar incorrectly 2 [7]----- equal precedence on stackWINE_foo correctly 1@or_broken@ERROR: WINE_foo incorrectly 0 [1]WINE_foo correctly 0WINE_foo correctly 1@or_broken@ERROR: WINE_foo incorrectly [1]WINE_foo correctly 0@or_broken@ERROR: WINE_foo incorrectly [0]WINE_foo correctly 1@or_broken@ERROR: WINE_foo incorrectly [1]WINE_foo correctly -1@or_broken@ERROR: WINE_foo incorrectly [-1]WINE_foo correctly -1@or_broken@ERROR: WINE_foo incorrectly [-1]WINE_foo correctly 1@or_broken@ERROR: WINE_foo incorrectly [1]WINE_foo correctly 0@or_broken@ERROR: WINE_foo incorrectly [0]WINE_foo correctly -1WINE_foo correctly 0@or_broken@ERROR: WINE_foo incorrectly -1 [0]WINE_foo correctly 0WINE_foo correctly 1@or_broken@ERROR: WINE_foo incorrectly 0 [1]WINE_foo correctly -1@or_broken@ERROR: WINE_foo incorrectly 0 [-1]WINE_foo correctly 25@or_broken@ERROR: WINE_foo incorrectly 20 [25]WINE_foo correctly 20WINE_foo correctly 1WINE_foo correctly 4WINE_foo correctly 7WINE_foo correctly 8@or_broken@ERROR: WINE_foo incorrectly 4 [8]WINE_foo correctly 6@or_broken@ERROR: WINE_foo incorrectly 5 [6]WINE_bar correctly 6@or_broken@ERROR: WINE_bar incorrectly 5 [6]--- for /F------ string argumentaXaXa@or_broken@no outputXaX@or_broken@no outputaa@or_broken@no outputaa@or_broken@no outputaa@or_broken@no outputaa@or_broken@no output------ fileset argument--------- basic blank handlingaaaaab--------- multi-line with empty linesabc--------- multiple filesabcqkkkqkkkabc------ command argumentPassed1@or_broken@Missing functionality - Broken1Passed2@or_broken@Missing functionality - Broken2Passed3@or_broken@Missing functionality - Broken3Passed4@or_broken@Missing functionality - Broken4Passed5@or_broken@Missing functionality - Broken5Passed6@or_broken@Missing functionality - Broken6Passed7@or_broken@Missing functionality - Broken7------ eol optionand@or_broken@Broken NT4 functionality1Line@or_broken@Broken NT4 functionality2Line@or_broken@Broken NT4 functionality3adz@ya|dno outputno output------ delims optionaa@space@a daC rfoo bar bazc:\------ skip optioncno outputno outputccno output------ tokens= optionh=%h i=a j=%j k=%k l=%l m=%m o=%oh=%h i=b j=%j k=%k l=%l m=%m o=%oh=%h i=a j=c k=e l=f m=g o=%oh=%h i=a j=e k=f g l=%l m=%m o=%oh=%h i=f j=i k=j k l m n o p q r s t u v w x y z l=%l m=%m o=%oh=%h i=f j=i k=j k l m n;;== o p q r s t u v w x y z l=%l m=%m o=%oh=%h i=a j=b k=c l=d e f g m=%m n=%n o=%oh=%h i=a j=b k=c l=d e f g m=%m n=%n o=%oh=%h i=a j=b k= l= m=%m n=%n o=%oh=%h i=a j=e k=y l=z A B C D E F G H I J K L M N O P Q R S T U V W X Y Z m=%m n=%n o=%oh=%h i=a j=b k= l= m= n=%n o=%oh=%h i=a j=b k= l= m= n= o=%ou=a v=b w=c x=d y=e z=f A=%A a=%a@todo_wine@U=a V=b W=c X=d Y=e Z=f A=%A a=mh=%h i=a j=b k=c l=e m=%m o=%o@or_broken@h=%h i=a j=b k=c l=e m= o=%oh=%h i=e j=%j k=%k l=%l m=%m o=%oh=%h i=a j=b k=c l=d e f g m=%m n=%n o=%o@or_broken@h=%h i=a j=b k=c l=d e f g m= n=%n o=%oh=%h i=a j=c k= l= m=%m n=%n o=%o@or_broken@h=%h i=a j=c k= l= m= n=%n o=%oh=%h i=b j=c k= l= m=%m n=%n o=%o@or_broken@h=%h i=b j=c k= l= m= n=%n o=%oh=%h i=b j=c k= l= m=%m n=%n o=%o@or_broken@h=%h i=b j=c k= l= m= n=%n o=%o1:3.14,%B2:3.14,4:3,14------ parameter splitting:forFParameterSplittingFunc myparam1=myvalue1 myparam2=myparam2 mytest@space@@space@@space@:forFParameterSplittingFunc myparam1=myvalue1 myparam2=myparam2 mytest@space@@space@@space@4:3.14,%B5:3,146:14,------------ Testing del ------------deleting 'file'errorlevel is 0, goodsuccessfully deleted 'file'attempting to delete 'file', even though it is not presenterrorlevel is 0, good------------ Testing del /a ------------not-r.test not found after delete, goodr.test found before delete, goodr.test not found after delete, good------------ Testing del /q ------------del /q * succeeded on file1del /q * succeeded on file2.dat------------ Testing del /s ------------------------ Testing rename --------------- ren and rename are synonymousfoo renamed to barbar renamed to foo--- name collisionfoobar--- rename read-only filesread-only file renamed--- rename directoriesdir renamedread-only dir renamed--- rename in other directoryrename impossible in other directoryoriginal file still present------------ Testing move --------------- file movefile move succeeded@todo_wine@file move with overwrite succeeded@or_broken@file overwrite impossible!@todo_wine@bar@or_broken@bazread-only files are moveablefile moved in subdirectorymoving a file to itself is a no-op@or_broken@moving a file to itself should be a no-op!ErrorLevel: 0@or_broken@ErrorLevel: 1--- directory movesimple directory move succeededmoving a directory to itself gives error; errlevel 1------ dir in dir movefoobar2foo2------------ Testing mkdir --------------- md and mkdir are synonymous00--- creating an already existing directory/file must fail11--- multilevel path creation00000100--- trailing backslashes0dir created0--- invalid charsmkdir ? gives errorlevel 1mkdir ?\foo gives errorlevel 1mkdir foo\? gives errorlevel 1ok, foo createdmkdir foo\bar\? gives errorlevel 1ok, foo\bar created--- multiple directories at oncefoo createdbar createdfoobar createdbar\baz createdbazbaz createdzabzab createdmkdir foo\* errorlevel 1ok, foo created------------ Testing rmdir ------------0dir removed0dir removed00file not removed0non-empty dir not removed0non-empty dir not removedrecursive rmdir succeededrecursive rmdir succeededfoo removedbar removedfoobar removedbar\baz removed------------ Testing pushd/popd ------------@pwd@--- popd is no-op when dir stack is empty@pwd@--- pushing non-existing dir@pwd@--- basic behaviour@drive@@path@foobar@pwd@@drive@@path@foobar\baz@drive@@path@foobar@drive@@path@foobar@pwd@@drive@@path@foobar@pwd@------------ Testing attrib ------------A@spaces@@drive@@path@foobar\foo@or_broken@A I@spaces@@drive@@path@foobar\foo--- read-only attributeA R@spaces@@drive@@path@foobar\foo@or_broken@A R I@spaces@@drive@@path@foobar\foofoofoo original contentsRead-only file not deletedRead-only file forcibly deleted--- recursive behaviourA@spaces@@drive@@path@foobar\baz\level2@or_broken@A I@spaces@@drive@@path@foobar\baz\level2A R@spaces@@drive@@path@foobar\level1@or_broken@A R I@spaces@@drive@@path@foobar\level1A R@spaces@@drive@@path@foobar\baz\level2@or_broken@A R I@spaces@@drive@@path@foobar\baz\level2A@spaces@@drive@@path@foobar\bar@or_broken@A I@spaces@@drive@@path@foobar\bar--- folders processing@spaces@@drive@@path@foobar@or_broken@ I@spaces@@drive@@path@foobar@todo_wine@ R@spaces@@drive@@path@foobar\baz@or_broken@@spaces@@drive@@path@foobar\baz@or_broken@ R I@spaces@@drive@@path@foobar\bazA@spaces@@drive@@path@foobar\baz\toto@or_broken@A I@spaces@@drive@@path@foobar\baz\totototolulufile created in read-only dir------------ Testing assoc --------------- setting association---.foo=bar.foo=bar+++.foo=bar--- resetting association---+++--------------- Testing ftype --------------- setting association---footype=foo_opencmd.foo=footypefootype=foo_opencmd+++footype=foo_opencmd--- resetting association@todo_wine@original value@or_broken@buggyXP@or_broken@!WINE_FOO!------------ Testing CALL --------------- external scriptfoo@space@foo 8foo@space@@space@foo bar@space@foo ""@space@"" bar@space@foo ''@space@'' bar@space@--- internal routinesbar :testRoutinefoo@space@foo barfoo """" barfoo '''' bar--- with builtins0foo createdShould expand foobazbatfilerobinfile11non-builtin dirLine oneLine twoGet if... and else!passed------------ Testing SHIFT ------------'p1' 'p2' 'p3' 'p4' 'p5''p2' 'p3' 'p4' 'p5' '''p3' 'p4' 'p5' '' '''p3' 'p5' '' '' '''p3' 'p5' '' '' '''p5' '' '' '' ''------------ Testing cmd invocation --------------- a batch file can delete itselffile correctly deleted--- a batch file can alter itselfbar---------- Testing copyPassed: Found expected dummy.filePassed: Found expected dir1\file1Passed: Found expected dir1\file1Passed: Found expected dir1\file99Passed: Found expected file1Passed: Did not find dir2Passed: Did not find dir2\file1Passed: Found expected dir1\file1Passed: Found expected dir1\file2Passed: Found expected dir1\file3Passed: Found expected dir1\file1Passed: Found expected dir1\file2Passed: Found expected dir1\file3Passed: Found expected file1Passed: Found expected file2Passed: Found expected file3Passed: Did not find dir2Passed: Did not find dir2\file1Passed: Did not find dir2\file2Passed: Did not find dir2\file3Passed: Found expected testfilePassed: Found expected testfilePassed: Found expected testfilePassed: Found expected testfilePassed: Found expected testfilePassed: Found expected dir1\fredPassed: Found expected dir1\fredPassed: Found expected fredPassed: Found expected fredPassed: file size check on file1 [5]@or_broken@Skipping file size check on NT4Passed: file size check on file2 [8]@or_broken@Skipping file size check on NT4Passed: file size check on file3 [11]@or_broken@Skipping file size check on NT4Passed: file size check on file1_default [5]@or_broken@Skipping file size check on NT4Passed: file size check on file1_default2 [5]@or_broken@Skipping file size check on NT4Passed: file size check on file1_plus_eof [6]@or_broken@Skipping file size check on NT4Passed: file size check on file2_plus_eof [9]@or_broken@Skipping file size check on NT4Passed: file size check on file3_plus_eof [12]@or_broken@Skipping file size check on NT4Passed: file size check on file12_plus_eof [14]@or_broken@Skipping file size check on NT4Passed: file size check on file12_no_eof [13]@or_broken@Skipping file size check on NT4Passed: file size check on file12_eof2 [14]@or_broken@Skipping file size check on NT4Passed: file size check on file1 [24]@or_broken@Skipping file size check on NT4Passed: file size check on file2 [16]@or_broken@Skipping file size check on NT4Passed: file size check on file3 [13]@or_broken@Skipping file size check on NT4Passed: file size check on file1_binary_srccopy [6]@or_broken@Skipping file size check on NT4Passed: file size check on file1_ascii_srccopy [5]@or_broken@Skipping file size check on NT4Passed: file size check on file123_default_copy [25]@or_broken@Skipping file size check on NT4Passed: file size check on file123_ascii_copy [25]@or_broken@Skipping file size check on NT4Passed: file size check on file123_binary_copy [27]@or_broken@Skipping file size check on NT4Passed: file size check on file123_mixed_copy1 [26]@or_broken@Skipping file size check on NT4Passed: file size check on file123_mixed_copy2 [27]@or_broken@Skipping file size check on NT4Passed: file size check on file123_mixed_copy3 [26]@or_broken@Skipping file size check on NT4Passed: file size check on file123_mixed_copy4 [25]@or_broken@Skipping file size check on NT4Passed: file size check on file123_mixed_copy5 [28]@or_broken@Skipping file size check on NT4Passed: file size check on file123_mixed_copy6 [19]@or_broken@Skipping file size check on NT4Passed: file size check on file123_mixed_copy7 [6]@or_broken@Skipping file size check on NT4Passed: file size check on file123_mixed_copy8 [7]@or_broken@Skipping file size check on NT4Passed: errorlevel invalid check 1Passed: Did not find dir1\file1Passed: errorlevel invalid check 2Passed: errorlevel invalid check 3------------ Testing setlocal/endlocal --------------- enable/disable extensions@todo_wine@ErrLev:@space@ErrLev: 0ErrLev: 0@todo_wine@ErrLev:@space@@or_broken@ErrLev: 0ErrLev: 0--- setlocal with corresponding endlocalglobalvallocalval@drive@@path@foobar\foobar2globalval@drive@@path@foobarglobalval@drive@@path@foobar--- setlocal with no corresponding endlocalglobalvallocalval@drive@@path@foobar\foobar2globalval@drive@@path@foobar--- setlocal within same batch programVar1 ok 1Var2 ok 2Var3 ok 3Directory is ok 1Var1 ok 1Var2 ok 2Var3 ok 3Directory is ok 2Var1 ok 1Var2 ok 2Var3 ok 3Directory is ok 3--- Mismatched set and end locals--- Extra setlocal in called batchvalue22set1endvalue1@drive@@path@foobar\foodir3Finished:value2@drive@@path@foobar\foodir2value1@drive@@path@foobar--- Extra endlocal in called batchvalue2value2@drive@@path@foobar\foodir2value2@drive@@path@foobar\foodir2Finished:value2@drive@@path@foobar\foodir2value1@drive@@path@foobar--- endlocal in called function rather than batch pgm is ineffective22121211------------ Testing Errorlevel ------------90091errorlevel just right, gooderrorlevel with leading zero just right, gooderrorlevel with negative number OKabc0def@or_broken@abc1deferrorlevel zero, good@or_broken@errorlevel nonzero, bad7 should be 77 should still be 7------------ Testing GOTO ------------goto with no leading space workedgoto with colon and no leading space workedgoto with a leading space workedgoto with a leading tab workedgoto with a following space workedgoto with following amphersands workedgoto with redirections workedIgnoring double colons workedlabel with mixed whitespace and no echo workedCorrectly ignored trailing informationBegin:..First sub..First subMiddle:..Third sub..Third subNear end:..Fourth sub..Fourth subAt end:..First sub..First subFinished------------ Testing PATH ------------PATH=originalPATH=try2PATH=try3------------ Testing start /W ------------start /W seems to really wait------------ Testing changing the drive letter ----------Normal:Normal+spaceNormal+space+garbageQuoted should failNormal+tabNormal+tab+garbage------------ Testing combined CALLs/GOTOs ------------worldcheballbarbarebarfoobazcheballbarbare