Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
74566422
Commit
74566422
authored
Aug 29, 2011
by
Frédéric Delanoy
Committed by
Alexandre Julliard
Aug 30, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cmd/tests: Add ftype tests.
parent
caa8fc04
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
52 additions
and
0 deletions
+52
-0
test_builtins.cmd
programs/cmd/tests/test_builtins.cmd
+42
-0
test_builtins.cmd.exp
programs/cmd/tests/test_builtins.cmd.exp
+10
-0
No files found.
programs/cmd/tests/test_builtins.cmd
View file @
74566422
...
...
@@ -1113,6 +1113,48 @@ type baz
echo ***
cd .. & rd /s/q foobar
echo ------------ Testing ftype --------------
rem FIXME Can't test error messages in the current test system, so we have to use some kludges
rem FIXME Revise once || conditional execution is fixed
mkdir foobar & cd foobar
echo ...setting association
ftype footype> baz
type baz
echo ***
ftype footype=foo_opencmd
assoc .foo=footype
ftype footype
rem association set system-wide
echo @echo off> tmp.cmd
echo echo +++>> tmp.cmd
echo ftype footype>> tmp.cmd
cmd /c tmp.cmd
echo ...resetting association
assoc .foo=
rem Removing a file type association doesn't work on XP due to a bug, so a workaround is needed
setlocal EnableDelayedExpansion
set FOO=original value
ftype footype=
ftype footype > baz
for /F %%i in ('type baz') do (set FOO=buggyXP)
rem Resetting actually works on wine/NT4, but is reported as failing due to the peculiar test (and non-support for EnabledDelayedExpansion)
rem FIXME Revisit once a grep-like program like ftype is implemented
rem (e.g. to check baz's size using dir /b instead)
echo !FOO!
rem cleanup registry
echo REGEDIT4> regCleanup.reg
echo.>> regCleanup.reg
echo [-HKEY_CLASSES_ROOT\footype]>> regCleanup.reg
regedit /s regCleanup.reg
set FOO=
endlocal
cd .. & rd /s/q foobar
echo ------------ Testing CALL --------------
mkdir foobar & cd foobar
rem External script
...
...
programs/cmd/tests/test_builtins.cmd.exp
View file @
74566422
...
...
@@ -665,6 +665,16 @@ file created in read-only dir
***
+++
***
------------ Testing ftype --------------
...setting association
***
footype=foo_opencmd
.foo=footype
footype=foo_opencmd
+++
footype=foo_opencmd
...resetting association
@todo_wine@original value@or_broken@buggyXP@or_broken@!FOO!
------------ Testing CALL --------------
foo@space@
foo 8
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment