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
5dd87ec9
Commit
5dd87ec9
authored
Feb 12, 2009
by
Juan Lang
Committed by
Alexandre Julliard
Feb 13, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32: Log more information in case of a test failure, and don't run tests…
kernel32: Log more information in case of a test failure, and don't run tests that are guaranteed to fail.
parent
0edcef6d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
21 deletions
+26
-21
file.c
dlls/kernel32/tests/file.c
+26
-21
No files found.
dlls/kernel32/tests/file.c
View file @
5dd87ec9
...
...
@@ -2217,27 +2217,32 @@ static void test_ReplaceFileA(void)
/* make sure that the "replaced" file has the size of the replacement file */
hReplacedFile
=
CreateFileA
(
replaced
,
GENERIC_READ
,
FILE_SHARE_READ
,
NULL
,
OPEN_EXISTING
,
0
,
0
);
ok
(
hReplacedFile
!=
INVALID_HANDLE_VALUE
,
"failed to open replaced file
\n
"
);
ret
=
GetFileSize
(
hReplacedFile
,
NULL
);
ok
(
ret
==
sizeof
(
replacementData
),
"replaced file has wrong size %d
\n
"
,
ret
);
/* make sure that the replacement file no-longer exists */
hReplacementFile
=
CreateFileA
(
replacement
,
GENERIC_READ
,
FILE_SHARE_READ
,
NULL
,
OPEN_EXISTING
,
0
,
0
);
ok
(
hReplacementFile
==
INVALID_HANDLE_VALUE
,
"unexpected error, replacement file should not exist %d
\n
"
,
GetLastError
());
/* make sure that the backup has the old "replaced" filetime */
ret
=
GetFileTime
(
hBackupFile
,
NULL
,
NULL
,
&
ftBackup
);
ok
(
ret
,
"GetFileTime error (backup %d
\n
"
,
GetLastError
());
ok
(
check_file_time
(
&
ftBackup
,
&
ftReplaced
,
20000000
),
"backup file has wrong filetime
\n
"
);
CloseHandle
(
hBackupFile
);
/* make sure that the "replaced" has the old replacement filetime */
ret
=
GetFileTime
(
hReplacedFile
,
NULL
,
NULL
,
&
ftReplaced
);
ok
(
ret
,
"GetFileTime error (backup %d
\n
"
,
GetLastError
());
ok
(
check_file_time
(
&
ftReplaced
,
&
ftReplacement
,
20000000
),
"replaced file has wrong filetime %x%08x / %x%08x
\n
"
,
ftReplaced
.
dwHighDateTime
,
ftReplaced
.
dwLowDateTime
,
ftReplacement
.
dwHighDateTime
,
ftReplacement
.
dwLowDateTime
);
CloseHandle
(
hReplacedFile
);
"failed to open replaced file: %d
\n
"
,
GetLastError
());
if
(
hReplacedFile
!=
INVALID_HANDLE_VALUE
)
{
ret
=
GetFileSize
(
hReplacedFile
,
NULL
);
ok
(
ret
==
sizeof
(
replacementData
),
"replaced file has wrong size %d
\n
"
,
ret
);
/* make sure that the replacement file no-longer exists */
hReplacementFile
=
CreateFileA
(
replacement
,
GENERIC_READ
,
FILE_SHARE_READ
,
NULL
,
OPEN_EXISTING
,
0
,
0
);
ok
(
hReplacementFile
==
INVALID_HANDLE_VALUE
,
"unexpected error, replacement file should not exist %d
\n
"
,
GetLastError
());
/* make sure that the backup has the old "replaced" filetime */
ret
=
GetFileTime
(
hBackupFile
,
NULL
,
NULL
,
&
ftBackup
);
ok
(
ret
,
"GetFileTime error (backup %d
\n
"
,
GetLastError
());
ok
(
check_file_time
(
&
ftBackup
,
&
ftReplaced
,
20000000
),
"backup file has wrong filetime
\n
"
);
CloseHandle
(
hBackupFile
);
/* make sure that the "replaced" has the old replacement filetime */
ret
=
GetFileTime
(
hReplacedFile
,
NULL
,
NULL
,
&
ftReplaced
);
ok
(
ret
,
"GetFileTime error (backup %d
\n
"
,
GetLastError
());
ok
(
check_file_time
(
&
ftReplaced
,
&
ftReplacement
,
20000000
),
"replaced file has wrong filetime %x%08x / %x%08x
\n
"
,
ftReplaced
.
dwHighDateTime
,
ftReplaced
.
dwLowDateTime
,
ftReplacement
.
dwHighDateTime
,
ftReplacement
.
dwLowDateTime
);
CloseHandle
(
hReplacedFile
);
}
else
skip
(
"couldn't open replacement file, skipping tests
\n
"
);
/* re-create replacement file for pass w/o backup (blank) */
ret
=
GetTempFileNameA
(
temp_path
,
prefix
,
0
,
replacement
);
...
...
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