Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
a29bbda1
Commit
a29bbda1
authored
Dec 19, 2009
by
Nikolay Sivov
Committed by
Alexandre Julliard
Dec 21, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32/tests: Print line numbers in tests.
parent
48efba00
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
174 additions
and
174 deletions
+174
-174
actctx.c
dlls/kernel32/tests/actctx.c
+174
-174
No files found.
dlls/kernel32/tests/actctx.c
View file @
a29bbda1
...
...
@@ -278,7 +278,7 @@ static const detailed_info_t detailed_info2 = {
work_dir
,
};
static
void
test_detailed_info
(
HANDLE
handle
,
const
detailed_info_t
*
exinfo
)
static
void
test_detailed_info
(
HANDLE
handle
,
const
detailed_info_t
*
exinfo
,
int
line
)
{
ACTIVATION_CONTEXT_DETAILED_INFORMATION
detailed_info_tmp
,
*
detailed_info
;
SIZE_T
size
,
exsize
,
retsize
;
...
...
@@ -293,9 +293,9 @@ static void test_detailed_info(HANDLE handle, const detailed_info_t *exinfo)
b
=
pQueryActCtxW
(
0
,
handle
,
NULL
,
ActivationContextDetailedInformation
,
&
detailed_info_tmp
,
sizeof
(
detailed_info_tmp
),
&
size
);
ok
(
!
b
,
"QueryActCtx succeeded
\n
"
);
ok
(
GetLastError
()
==
ERROR_INSUFFICIENT_BUFFER
,
"GetLastError() = %u
\n
"
,
GetLastError
());
ok
(
size
==
exsize
,
"size=%ld, expected %ld
\n
"
,
size
,
exsize
);
ok
_
(
__FILE__
,
line
)
(
!
b
,
"QueryActCtx succeeded
\n
"
);
ok
_
(
__FILE__
,
line
)
(
GetLastError
()
==
ERROR_INSUFFICIENT_BUFFER
,
"GetLastError() = %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
size
==
exsize
,
"size=%ld, expected %ld
\n
"
,
size
,
exsize
);
}
else
{
size
=
sizeof
(
ACTIVATION_CONTEXT_DETAILED_INFORMATION
);
}
...
...
@@ -305,53 +305,53 @@ static void test_detailed_info(HANDLE handle, const detailed_info_t *exinfo)
b
=
pQueryActCtxW
(
0
,
handle
,
NULL
,
ActivationContextDetailedInformation
,
detailed_info
,
size
,
&
retsize
);
ok
(
b
,
"QueryActCtx failed: %u
\n
"
,
GetLastError
());
ok
(
retsize
==
exsize
,
"size=%ld, expected %ld
\n
"
,
retsize
,
exsize
);
ok
_
(
__FILE__
,
line
)
(
b
,
"QueryActCtx failed: %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
retsize
==
exsize
,
"size=%ld, expected %ld
\n
"
,
retsize
,
exsize
);
ok
(
detailed_info
->
dwFlags
==
0
,
"detailed_info->dwFlags=%x
\n
"
,
detailed_info
->
dwFlags
);
ok
(
detailed_info
->
ulFormatVersion
==
exinfo
->
format_version
,
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
dwFlags
==
0
,
"detailed_info->dwFlags=%x
\n
"
,
detailed_info
->
dwFlags
);
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
ulFormatVersion
==
exinfo
->
format_version
,
"detailed_info->ulFormatVersion=%u, expected %u
\n
"
,
detailed_info
->
ulFormatVersion
,
exinfo
->
format_version
);
ok
(
exinfo
->
assembly_cnt_min
<=
detailed_info
->
ulAssemblyCount
&&
ok
_
(
__FILE__
,
line
)
(
exinfo
->
assembly_cnt_min
<=
detailed_info
->
ulAssemblyCount
&&
detailed_info
->
ulAssemblyCount
<=
exinfo
->
assembly_cnt_max
,
"detailed_info->ulAssemblyCount=%u, expected between %u and %u
\n
"
,
detailed_info
->
ulAssemblyCount
,
exinfo
->
assembly_cnt_min
,
exinfo
->
assembly_cnt_max
);
ok
(
detailed_info
->
ulRootManifestPathType
==
exinfo
->
root_manifest_type
,
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
ulRootManifestPathType
==
exinfo
->
root_manifest_type
,
"detailed_info->ulRootManifestPathType=%u, expected %u
\n
"
,
detailed_info
->
ulRootManifestPathType
,
exinfo
->
root_manifest_type
);
ok
(
detailed_info
->
ulRootManifestPathChars
==
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
ulRootManifestPathChars
==
(
exinfo
->
root_manifest_path
?
lstrlenW
(
exinfo
->
root_manifest_path
)
:
0
),
"detailed_info->ulRootManifestPathChars=%u, expected %u
\n
"
,
detailed_info
->
ulRootManifestPathChars
,
exinfo
->
root_manifest_path
?
lstrlenW
(
exinfo
->
root_manifest_path
)
:
0
);
ok
(
detailed_info
->
ulRootConfigurationPathType
==
exinfo
->
root_config_type
,
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
ulRootConfigurationPathType
==
exinfo
->
root_config_type
,
"detailed_info->ulRootConfigurationPathType=%u, expected %u
\n
"
,
detailed_info
->
ulRootConfigurationPathType
,
exinfo
->
root_config_type
);
ok
(
detailed_info
->
ulRootConfigurationPathChars
==
0
,
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
ulRootConfigurationPathChars
==
0
,
"detailed_info->ulRootConfigurationPathChars=%d
\n
"
,
detailed_info
->
ulRootConfigurationPathChars
);
ok
(
detailed_info
->
ulAppDirPathType
==
exinfo
->
app_dir_type
,
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
ulAppDirPathType
==
exinfo
->
app_dir_type
,
"detailed_info->ulAppDirPathType=%u, expected %u
\n
"
,
detailed_info
->
ulAppDirPathType
,
exinfo
->
app_dir_type
);
ok
(
detailed_info
->
ulAppDirPathChars
==
(
exinfo
->
app_dir
?
lstrlenW
(
exinfo
->
app_dir
)
:
0
),
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
ulAppDirPathChars
==
(
exinfo
->
app_dir
?
lstrlenW
(
exinfo
->
app_dir
)
:
0
),
"detailed_info->ulAppDirPathChars=%u, expected %u
\n
"
,
detailed_info
->
ulAppDirPathChars
,
exinfo
->
app_dir
?
lstrlenW
(
exinfo
->
app_dir
)
:
0
);
if
(
exinfo
->
root_manifest_path
)
{
ok
(
detailed_info
->
lpRootManifestPath
!=
NULL
,
"detailed_info->lpRootManifestPath == NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
lpRootManifestPath
!=
NULL
,
"detailed_info->lpRootManifestPath == NULL
\n
"
);
if
(
detailed_info
->
lpRootManifestPath
)
ok
(
!
lstrcmpiW
(
detailed_info
->
lpRootManifestPath
,
exinfo
->
root_manifest_path
),
ok
_
(
__FILE__
,
line
)
(
!
lstrcmpiW
(
detailed_info
->
lpRootManifestPath
,
exinfo
->
root_manifest_path
),
"unexpected detailed_info->lpRootManifestPath
\n
"
);
}
else
{
ok
(
detailed_info
->
lpRootManifestPath
==
NULL
,
"detailed_info->lpRootManifestPath != NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
lpRootManifestPath
==
NULL
,
"detailed_info->lpRootManifestPath != NULL
\n
"
);
}
ok
(
detailed_info
->
lpRootConfigurationPath
==
NULL
,
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
lpRootConfigurationPath
==
NULL
,
"detailed_info->lpRootConfigurationPath=%p
\n
"
,
detailed_info
->
lpRootConfigurationPath
);
if
(
exinfo
->
app_dir
)
{
ok
(
detailed_info
->
lpAppDirPath
!=
NULL
,
"detailed_info->lpAppDirPath == NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
lpAppDirPath
!=
NULL
,
"detailed_info->lpAppDirPath == NULL
\n
"
);
if
(
detailed_info
->
lpAppDirPath
)
ok
(
!
lstrcmpiW
(
exinfo
->
app_dir
,
detailed_info
->
lpAppDirPath
),
ok
_
(
__FILE__
,
line
)
(
!
lstrcmpiW
(
exinfo
->
app_dir
,
detailed_info
->
lpAppDirPath
),
"unexpected detailed_info->lpAppDirPath
\n
%s
\n
"
,
strw
(
detailed_info
->
lpAppDirPath
));
}
else
{
ok
(
detailed_info
->
lpAppDirPath
==
NULL
,
"detailed_info->lpAppDirPath != NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
detailed_info
->
lpAppDirPath
==
NULL
,
"detailed_info->lpAppDirPath != NULL
\n
"
);
}
HeapFree
(
GetProcessHeap
(),
0
,
detailed_info
);
...
...
@@ -419,7 +419,7 @@ static const info_in_assembly manifest_comctrl_info = {
0
,
NULL
,
NULL
,
TRUE
/* These values may differ between Windows installations */
};
static
void
test_info_in_assembly
(
HANDLE
handle
,
DWORD
id
,
const
info_in_assembly
*
exinfo
)
static
void
test_info_in_assembly
(
HANDLE
handle
,
DWORD
id
,
const
info_in_assembly
*
exinfo
,
int
line
)
{
ACTIVATION_CONTEXT_ASSEMBLY_DETAILED_INFORMATION
*
info
,
info_tmp
;
SIZE_T
size
,
exsize
;
...
...
@@ -434,10 +434,10 @@ static void test_info_in_assembly(HANDLE handle, DWORD id, const info_in_assembl
b
=
pQueryActCtxW
(
0
,
handle
,
&
id
,
AssemblyDetailedInformationInActivationContext
,
&
info_tmp
,
sizeof
(
info_tmp
),
&
size
);
ok
(
!
b
,
"QueryActCtx succeeded
\n
"
);
ok
(
GetLastError
()
==
ERROR_INSUFFICIENT_BUFFER
,
"GetLastError() = %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
!
b
,
"QueryActCtx succeeded
\n
"
);
ok
_
(
__FILE__
,
line
)
(
GetLastError
()
==
ERROR_INSUFFICIENT_BUFFER
,
"GetLastError() = %u
\n
"
,
GetLastError
());
ok
(
size
>=
exsize
,
"size=%lu, expected %lu
\n
"
,
size
,
exsize
);
ok
_
(
__FILE__
,
line
)
(
size
>=
exsize
,
"size=%lu, expected %lu
\n
"
,
size
,
exsize
);
if
(
size
==
0xdeadbeef
)
{
...
...
@@ -451,88 +451,88 @@ static void test_info_in_assembly(HANDLE handle, DWORD id, const info_in_assembl
size
=
0xdeadbeef
;
b
=
pQueryActCtxW
(
0
,
handle
,
&
id
,
AssemblyDetailedInformationInActivationContext
,
info
,
size
,
&
size
);
ok
(
b
,
"QueryActCtx failed: %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
b
,
"QueryActCtx failed: %u
\n
"
,
GetLastError
());
if
(
!
exinfo
->
manifest_path
)
exsize
+=
info
->
ulManifestPathLength
+
sizeof
(
WCHAR
);
if
(
!
exinfo
->
encoded_assembly_id
)
exsize
+=
info
->
ulEncodedAssemblyIdentityLength
+
sizeof
(
WCHAR
);
if
(
exinfo
->
has_assembly_dir
)
exsize
+=
info
->
ulAssemblyDirectoryNameLength
+
sizeof
(
WCHAR
);
ok
(
size
==
exsize
,
"size=%lu, expected %lu
\n
"
,
size
,
exsize
);
ok
_
(
__FILE__
,
line
)
(
size
==
exsize
,
"size=%lu, expected %lu
\n
"
,
size
,
exsize
);
if
(
0
)
/* FIXME: flags meaning unknown */
{
ok
((
info
->
ulFlags
)
==
exinfo
->
flags
,
"info->ulFlags = %x, expected %x
\n
"
,
ok
_
(
__FILE__
,
line
)
((
info
->
ulFlags
)
==
exinfo
->
flags
,
"info->ulFlags = %x, expected %x
\n
"
,
info
->
ulFlags
,
exinfo
->
flags
);
}
if
(
exinfo
->
encoded_assembly_id
)
{
len
=
strlen_aw
(
exinfo
->
encoded_assembly_id
)
*
sizeof
(
WCHAR
);
ok
(
info
->
ulEncodedAssemblyIdentityLength
==
len
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulEncodedAssemblyIdentityLength
==
len
,
"info->ulEncodedAssemblyIdentityLength = %u, expected %u
\n
"
,
info
->
ulEncodedAssemblyIdentityLength
,
len
);
}
else
{
ok
(
info
->
ulEncodedAssemblyIdentityLength
!=
0
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulEncodedAssemblyIdentityLength
!=
0
,
"info->ulEncodedAssemblyIdentityLength == 0
\n
"
);
}
ok
(
info
->
ulManifestPathType
==
ACTIVATION_CONTEXT_PATH_TYPE_WIN32_FILE
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulManifestPathType
==
ACTIVATION_CONTEXT_PATH_TYPE_WIN32_FILE
,
"info->ulManifestPathType = %x
\n
"
,
info
->
ulManifestPathType
);
if
(
exinfo
->
manifest_path
)
{
len
=
lstrlenW
(
exinfo
->
manifest_path
)
*
sizeof
(
WCHAR
);
ok
(
info
->
ulManifestPathLength
==
len
,
"info->ulManifestPathLength = %u, expected %u
\n
"
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulManifestPathLength
==
len
,
"info->ulManifestPathLength = %u, expected %u
\n
"
,
info
->
ulManifestPathLength
,
len
);
}
else
{
ok
(
info
->
ulManifestPathLength
!=
0
,
"info->ulManifestPathLength == 0
\n
"
);
ok
_
(
__FILE__
,
line
)
(
info
->
ulManifestPathLength
!=
0
,
"info->ulManifestPathLength == 0
\n
"
);
}
ok
(
info
->
ulPolicyPathType
==
ACTIVATION_CONTEXT_PATH_TYPE_NONE
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulPolicyPathType
==
ACTIVATION_CONTEXT_PATH_TYPE_NONE
,
"info->ulPolicyPathType = %x
\n
"
,
info
->
ulPolicyPathType
);
ok
(
info
->
ulPolicyPathLength
==
0
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulPolicyPathLength
==
0
,
"info->ulPolicyPathLength = %u, expected 0
\n
"
,
info
->
ulPolicyPathLength
);
ok
(
info
->
ulMetadataSatelliteRosterIndex
==
0
,
"info->ulMetadataSatelliteRosterIndex = %x
\n
"
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulMetadataSatelliteRosterIndex
==
0
,
"info->ulMetadataSatelliteRosterIndex = %x
\n
"
,
info
->
ulMetadataSatelliteRosterIndex
);
ok
(
info
->
ulManifestVersionMajor
==
1
,
"info->ulManifestVersionMajor = %x
\n
"
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulManifestVersionMajor
==
1
,
"info->ulManifestVersionMajor = %x
\n
"
,
info
->
ulManifestVersionMajor
);
ok
(
info
->
ulManifestVersionMinor
==
0
,
"info->ulManifestVersionMinor = %x
\n
"
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulManifestVersionMinor
==
0
,
"info->ulManifestVersionMinor = %x
\n
"
,
info
->
ulManifestVersionMinor
);
ok
(
info
->
ulPolicyVersionMajor
==
0
,
"info->ulPolicyVersionMajor = %x
\n
"
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulPolicyVersionMajor
==
0
,
"info->ulPolicyVersionMajor = %x
\n
"
,
info
->
ulPolicyVersionMajor
);
ok
(
info
->
ulPolicyVersionMinor
==
0
,
"info->ulPolicyVersionMinor = %x
\n
"
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulPolicyVersionMinor
==
0
,
"info->ulPolicyVersionMinor = %x
\n
"
,
info
->
ulPolicyVersionMinor
);
if
(
exinfo
->
has_assembly_dir
)
ok
(
info
->
ulAssemblyDirectoryNameLength
!=
0
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulAssemblyDirectoryNameLength
!=
0
,
"info->ulAssemblyDirectoryNameLength == 0
\n
"
);
else
ok
(
info
->
ulAssemblyDirectoryNameLength
==
0
,
ok
_
(
__FILE__
,
line
)
(
info
->
ulAssemblyDirectoryNameLength
==
0
,
"info->ulAssemblyDirectoryNameLength != 0
\n
"
);
ok
(
info
->
lpAssemblyEncodedAssemblyIdentity
!=
NULL
,
ok
_
(
__FILE__
,
line
)
(
info
->
lpAssemblyEncodedAssemblyIdentity
!=
NULL
,
"info->lpAssemblyEncodedAssemblyIdentity == NULL
\n
"
);
if
(
info
->
lpAssemblyEncodedAssemblyIdentity
&&
exinfo
->
encoded_assembly_id
)
{
ok
(
!
strcmp_aw
(
info
->
lpAssemblyEncodedAssemblyIdentity
,
exinfo
->
encoded_assembly_id
),
ok
_
(
__FILE__
,
line
)
(
!
strcmp_aw
(
info
->
lpAssemblyEncodedAssemblyIdentity
,
exinfo
->
encoded_assembly_id
),
"unexpected info->lpAssemblyEncodedAssemblyIdentity %s / %s
\n
"
,
strw
(
info
->
lpAssemblyEncodedAssemblyIdentity
),
exinfo
->
encoded_assembly_id
);
}
if
(
exinfo
->
manifest_path
)
{
ok
(
info
->
lpAssemblyManifestPath
!=
NULL
,
"info->lpAssemblyManifestPath == NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
info
->
lpAssemblyManifestPath
!=
NULL
,
"info->lpAssemblyManifestPath == NULL
\n
"
);
if
(
info
->
lpAssemblyManifestPath
)
ok
(
!
lstrcmpiW
(
info
->
lpAssemblyManifestPath
,
exinfo
->
manifest_path
),
ok
_
(
__FILE__
,
line
)
(
!
lstrcmpiW
(
info
->
lpAssemblyManifestPath
,
exinfo
->
manifest_path
),
"unexpected info->lpAssemblyManifestPath
\n
"
);
}
else
{
ok
(
info
->
lpAssemblyManifestPath
!=
NULL
,
"info->lpAssemblyManifestPath == NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
info
->
lpAssemblyManifestPath
!=
NULL
,
"info->lpAssemblyManifestPath == NULL
\n
"
);
}
ok
(
info
->
lpAssemblyPolicyPath
==
NULL
,
"info->lpAssemblyPolicyPath != NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
info
->
lpAssemblyPolicyPath
==
NULL
,
"info->lpAssemblyPolicyPath != NULL
\n
"
);
if
(
info
->
lpAssemblyPolicyPath
)
ok
(
*
(
WORD
*
)
info
->
lpAssemblyPolicyPath
==
0
,
"info->lpAssemblyPolicyPath is not empty
\n
"
);
ok
_
(
__FILE__
,
line
)
(
*
(
WORD
*
)
info
->
lpAssemblyPolicyPath
==
0
,
"info->lpAssemblyPolicyPath is not empty
\n
"
);
if
(
exinfo
->
has_assembly_dir
)
ok
(
info
->
lpAssemblyDirectoryName
!=
NULL
,
"info->lpAssemblyDirectoryName == NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
info
->
lpAssemblyDirectoryName
!=
NULL
,
"info->lpAssemblyDirectoryName == NULL
\n
"
);
else
ok
(
info
->
lpAssemblyDirectoryName
==
NULL
,
"info->lpAssemblyDirectoryName = %s
\n
"
,
ok
_
(
__FILE__
,
line
)
(
info
->
lpAssemblyDirectoryName
==
NULL
,
"info->lpAssemblyDirectoryName = %s
\n
"
,
strw
(
info
->
lpAssemblyDirectoryName
));
HeapFree
(
GetProcessHeap
(),
0
,
info
);
}
static
void
test_file_info
(
HANDLE
handle
,
ULONG
assid
,
ULONG
fileid
,
LPCWSTR
filename
)
static
void
test_file_info
(
HANDLE
handle
,
ULONG
assid
,
ULONG
fileid
,
LPCWSTR
filename
,
int
line
)
{
ASSEMBLY_FILE_DETAILED_INFORMATION
*
info
,
info_tmp
;
ACTIVATION_CONTEXT_QUERY_INDEX
index
=
{
assid
,
fileid
};
...
...
@@ -546,9 +546,9 @@ static void test_file_info(HANDLE handle, ULONG assid, ULONG fileid, LPCWSTR fil
b
=
pQueryActCtxW
(
0
,
handle
,
&
index
,
FileInformationInAssemblyOfAssemblyInActivationContext
,
&
info_tmp
,
sizeof
(
info_tmp
),
&
size
);
ok
(
!
b
,
"QueryActCtx succeeded
\n
"
);
ok
(
GetLastError
()
==
ERROR_INSUFFICIENT_BUFFER
,
"GetLastError() = %u
\n
"
,
GetLastError
());
ok
(
size
==
exsize
,
"size=%lu, expected %lu
\n
"
,
size
,
exsize
);
ok
_
(
__FILE__
,
line
)
(
!
b
,
"QueryActCtx succeeded
\n
"
);
ok
_
(
__FILE__
,
line
)
(
GetLastError
()
==
ERROR_INSUFFICIENT_BUFFER
,
"GetLastError() = %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
size
==
exsize
,
"size=%lu, expected %lu
\n
"
,
size
,
exsize
);
if
(
size
==
0xdeadbeef
)
{
...
...
@@ -561,18 +561,18 @@ static void test_file_info(HANDLE handle, ULONG assid, ULONG fileid, LPCWSTR fil
b
=
pQueryActCtxW
(
0
,
handle
,
&
index
,
FileInformationInAssemblyOfAssemblyInActivationContext
,
info
,
size
,
&
size
);
ok
(
b
,
"QueryActCtx failed: %u
\n
"
,
GetLastError
());
ok
(
!
size
,
"size=%lu, expected 0
\n
"
,
size
);
ok
_
(
__FILE__
,
line
)
(
b
,
"QueryActCtx failed: %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
!
size
,
"size=%lu, expected 0
\n
"
,
size
);
ok
(
info
->
ulFlags
==
2
,
"info->ulFlags=%x, expected 2
\n
"
,
info
->
ulFlags
);
ok
(
info
->
ulFilenameLength
==
lstrlenW
(
filename
)
*
sizeof
(
WCHAR
),
ok
_
(
__FILE__
,
line
)
(
info
->
ulFlags
==
2
,
"info->ulFlags=%x, expected 2
\n
"
,
info
->
ulFlags
);
ok
_
(
__FILE__
,
line
)
(
info
->
ulFilenameLength
==
lstrlenW
(
filename
)
*
sizeof
(
WCHAR
),
"info->ulFilenameLength=%u, expected %u*sizeof(WCHAR)
\n
"
,
info
->
ulFilenameLength
,
lstrlenW
(
filename
));
ok
(
info
->
ulPathLength
==
0
,
"info->ulPathLength=%u
\n
"
,
info
->
ulPathLength
);
ok
(
info
->
lpFileName
!=
NULL
,
"info->lpFileName == NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
info
->
ulPathLength
==
0
,
"info->ulPathLength=%u
\n
"
,
info
->
ulPathLength
);
ok
_
(
__FILE__
,
line
)
(
info
->
lpFileName
!=
NULL
,
"info->lpFileName == NULL
\n
"
);
if
(
info
->
lpFileName
)
ok
(
!
lstrcmpiW
(
info
->
lpFileName
,
filename
),
"unexpected info->lpFileName
\n
"
);
ok
(
info
->
lpFilePath
==
NULL
,
"info->lpFilePath != NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
!
lstrcmpiW
(
info
->
lpFileName
,
filename
),
"unexpected info->lpFileName
\n
"
);
ok
_
(
__FILE__
,
line
)
(
info
->
lpFilePath
==
NULL
,
"info->lpFilePath != NULL
\n
"
);
HeapFree
(
GetProcessHeap
(),
0
,
info
);
}
...
...
@@ -693,7 +693,7 @@ static void test_create_fail(void)
test_create_and_fail
(
manifest2
,
wrong_depmanifest1
,
0
);
}
static
void
test_find_dll_redirection
(
HANDLE
handle
,
LPCWSTR
libname
,
ULONG
exid
)
static
void
test_find_dll_redirection
(
HANDLE
handle
,
LPCWSTR
libname
,
ULONG
exid
,
int
line
)
{
ACTCTX_SECTION_KEYED_DATA
data
;
DWORD
*
p
;
...
...
@@ -705,32 +705,32 @@ static void test_find_dll_redirection(HANDLE handle, LPCWSTR libname, ULONG exid
ret
=
pFindActCtxSectionStringW
(
0
,
NULL
,
ACTIVATION_CONTEXT_SECTION_DLL_REDIRECTION
,
libname
,
&
data
);
ok
(
ret
,
"FindActCtxSectionStringW failed: %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
ret
,
"FindActCtxSectionStringW failed: %u
\n
"
,
GetLastError
());
if
(
!
ret
)
{
skip
(
"couldn't find %s
\n
"
,
strw
(
libname
));
return
;
}
ok
(
data
.
cbSize
==
sizeof
(
data
),
"data.cbSize=%u
\n
"
,
data
.
cbSize
);
ok
(
data
.
ulDataFormatVersion
==
1
,
"data.ulDataFormatVersion=%u
\n
"
,
data
.
ulDataFormatVersion
);
ok
(
data
.
lpData
!=
NULL
,
"data.lpData == NULL
\n
"
);
ok
(
data
.
ulLength
==
20
,
"data.ulLength=%u
\n
"
,
data
.
ulLength
);
ok
_
(
__FILE__
,
line
)
(
data
.
cbSize
==
sizeof
(
data
),
"data.cbSize=%u
\n
"
,
data
.
cbSize
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulDataFormatVersion
==
1
,
"data.ulDataFormatVersion=%u
\n
"
,
data
.
ulDataFormatVersion
);
ok
_
(
__FILE__
,
line
)
(
data
.
lpData
!=
NULL
,
"data.lpData == NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulLength
==
20
,
"data.ulLength=%u
\n
"
,
data
.
ulLength
);
p
=
data
.
lpData
;
if
(
ret
&&
p
)
todo_wine
{
ok
(
p
[
0
]
==
20
&&
p
[
1
]
==
2
&&
p
[
2
]
==
0
&&
p
[
3
]
==
0
&&
p
[
4
]
==
0
,
ok
_
(
__FILE__
,
line
)
(
p
[
0
]
==
20
&&
p
[
1
]
==
2
&&
p
[
2
]
==
0
&&
p
[
3
]
==
0
&&
p
[
4
]
==
0
,
"wrong data %u,%u,%u,%u,%u
\n
"
,
p
[
0
],
p
[
1
],
p
[
2
],
p
[
3
],
p
[
4
]);
}
ok
(
data
.
lpSectionGlobalData
==
NULL
,
"data.lpSectionGlobalData != NULL
\n
"
);
ok
(
data
.
ulSectionGlobalDataLength
==
0
,
"data.ulSectionGlobalDataLength=%u
\n
"
,
ok
_
(
__FILE__
,
line
)
(
data
.
lpSectionGlobalData
==
NULL
,
"data.lpSectionGlobalData != NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulSectionGlobalDataLength
==
0
,
"data.ulSectionGlobalDataLength=%u
\n
"
,
data
.
ulSectionGlobalDataLength
);
ok
(
data
.
lpSectionBase
!=
NULL
,
"data.lpSectionBase == NULL
\n
"
);
/* ok(data.ulSectionTotalLength == ??, "data.ulSectionTotalLength=%u\n",
ok
_
(
__FILE__
,
line
)
(
data
.
lpSectionBase
!=
NULL
,
"data.lpSectionBase == NULL
\n
"
);
/* ok
_(__FILE__, line)
(data.ulSectionTotalLength == ??, "data.ulSectionTotalLength=%u\n",
data.ulSectionTotalLength); */
ok
(
data
.
hActCtx
==
NULL
,
"data.hActCtx=%p
\n
"
,
data
.
hActCtx
);
ok
(
data
.
ulAssemblyRosterIndex
==
exid
,
"data.ulAssemblyRosterIndex=%u, expected %u
\n
"
,
ok
_
(
__FILE__
,
line
)
(
data
.
hActCtx
==
NULL
,
"data.hActCtx=%p
\n
"
,
data
.
hActCtx
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulAssemblyRosterIndex
==
exid
,
"data.ulAssemblyRosterIndex=%u, expected %u
\n
"
,
data
.
ulAssemblyRosterIndex
,
exid
);
memset
(
&
data
,
0xfe
,
sizeof
(
data
));
...
...
@@ -739,31 +739,31 @@ static void test_find_dll_redirection(HANDLE handle, LPCWSTR libname, ULONG exid
ret
=
pFindActCtxSectionStringW
(
FIND_ACTCTX_SECTION_KEY_RETURN_HACTCTX
,
NULL
,
ACTIVATION_CONTEXT_SECTION_DLL_REDIRECTION
,
libname
,
&
data
);
ok
(
ret
,
"FindActCtxSectionStringW failed: %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
ret
,
"FindActCtxSectionStringW failed: %u
\n
"
,
GetLastError
());
if
(
!
ret
)
{
skip
(
"couldn't find
\n
"
);
return
;
}
ok
(
data
.
cbSize
==
sizeof
(
data
),
"data.cbSize=%u
\n
"
,
data
.
cbSize
);
ok
(
data
.
ulDataFormatVersion
==
1
,
"data.ulDataFormatVersion=%u
\n
"
,
data
.
ulDataFormatVersion
);
ok
(
data
.
lpData
!=
NULL
,
"data.lpData == NULL
\n
"
);
ok
(
data
.
ulLength
==
20
,
"data.ulLength=%u
\n
"
,
data
.
ulLength
);
ok
(
data
.
lpSectionGlobalData
==
NULL
,
"data.lpSectionGlobalData != NULL
\n
"
);
ok
(
data
.
ulSectionGlobalDataLength
==
0
,
"data.ulSectionGlobalDataLength=%u
\n
"
,
ok
_
(
__FILE__
,
line
)
(
data
.
cbSize
==
sizeof
(
data
),
"data.cbSize=%u
\n
"
,
data
.
cbSize
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulDataFormatVersion
==
1
,
"data.ulDataFormatVersion=%u
\n
"
,
data
.
ulDataFormatVersion
);
ok
_
(
__FILE__
,
line
)
(
data
.
lpData
!=
NULL
,
"data.lpData == NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulLength
==
20
,
"data.ulLength=%u
\n
"
,
data
.
ulLength
);
ok
_
(
__FILE__
,
line
)
(
data
.
lpSectionGlobalData
==
NULL
,
"data.lpSectionGlobalData != NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulSectionGlobalDataLength
==
0
,
"data.ulSectionGlobalDataLength=%u
\n
"
,
data
.
ulSectionGlobalDataLength
);
ok
(
data
.
lpSectionBase
!=
NULL
,
"data.lpSectionBase == NULL
\n
"
);
/* ok(data.ulSectionTotalLength == ?? , "data.ulSectionTotalLength=%u\n",
ok
_
(
__FILE__
,
line
)
(
data
.
lpSectionBase
!=
NULL
,
"data.lpSectionBase == NULL
\n
"
);
/* ok
_(__FILE__, line)
(data.ulSectionTotalLength == ?? , "data.ulSectionTotalLength=%u\n",
data.ulSectionTotalLength); */
ok
(
data
.
hActCtx
==
handle
,
"data.hActCtx=%p
\n
"
,
data
.
hActCtx
);
ok
(
data
.
ulAssemblyRosterIndex
==
exid
,
"data.ulAssemblyRosterIndex=%u, expected %u
\n
"
,
ok
_
(
__FILE__
,
line
)
(
data
.
hActCtx
==
handle
,
"data.hActCtx=%p
\n
"
,
data
.
hActCtx
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulAssemblyRosterIndex
==
exid
,
"data.ulAssemblyRosterIndex=%u, expected %u
\n
"
,
data
.
ulAssemblyRosterIndex
,
exid
);
pReleaseActCtx
(
handle
);
}
static
void
test_find_window_class
(
HANDLE
handle
,
LPCWSTR
clsname
,
ULONG
exid
)
static
void
test_find_window_class
(
HANDLE
handle
,
LPCWSTR
clsname
,
ULONG
exid
,
int
line
)
{
ACTCTX_SECTION_KEYED_DATA
data
;
BOOL
ret
;
...
...
@@ -774,25 +774,25 @@ static void test_find_window_class(HANDLE handle, LPCWSTR clsname, ULONG exid)
ret
=
pFindActCtxSectionStringW
(
0
,
NULL
,
ACTIVATION_CONTEXT_SECTION_WINDOW_CLASS_REDIRECTION
,
clsname
,
&
data
);
ok
(
ret
,
"FindActCtxSectionStringW failed: %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
ret
,
"FindActCtxSectionStringW failed: %u
\n
"
,
GetLastError
());
if
(
!
ret
)
{
skip
(
"couldn't find
\n
"
);
return
;
}
ok
(
data
.
cbSize
==
sizeof
(
data
),
"data.cbSize=%u
\n
"
,
data
.
cbSize
);
ok
(
data
.
ulDataFormatVersion
==
1
,
"data.ulDataFormatVersion=%u
\n
"
,
data
.
ulDataFormatVersion
);
ok
(
data
.
lpData
!=
NULL
,
"data.lpData == NULL
\n
"
);
/* ok(data.ulLength == ??, "data.ulLength=%u\n", data.ulLength); */
ok
(
data
.
lpSectionGlobalData
==
NULL
,
"data.lpSectionGlobalData != NULL
\n
"
);
ok
(
data
.
ulSectionGlobalDataLength
==
0
,
"data.ulSectionGlobalDataLength=%u
\n
"
,
ok
_
(
__FILE__
,
line
)
(
data
.
cbSize
==
sizeof
(
data
),
"data.cbSize=%u
\n
"
,
data
.
cbSize
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulDataFormatVersion
==
1
,
"data.ulDataFormatVersion=%u
\n
"
,
data
.
ulDataFormatVersion
);
ok
_
(
__FILE__
,
line
)
(
data
.
lpData
!=
NULL
,
"data.lpData == NULL
\n
"
);
/* ok
_(__FILE__, line)
(data.ulLength == ??, "data.ulLength=%u\n", data.ulLength); */
ok
_
(
__FILE__
,
line
)
(
data
.
lpSectionGlobalData
==
NULL
,
"data.lpSectionGlobalData != NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulSectionGlobalDataLength
==
0
,
"data.ulSectionGlobalDataLength=%u
\n
"
,
data
.
ulSectionGlobalDataLength
);
ok
(
data
.
lpSectionBase
!=
NULL
,
"data.lpSectionBase == NULL
\n
"
);
/* ok(data.ulSectionTotalLength == 0, "data.ulSectionTotalLength=%u\n",
ok
_
(
__FILE__
,
line
)
(
data
.
lpSectionBase
!=
NULL
,
"data.lpSectionBase == NULL
\n
"
);
/* ok
_(__FILE__, line)
(data.ulSectionTotalLength == 0, "data.ulSectionTotalLength=%u\n",
data.ulSectionTotalLength); FIXME */
ok
(
data
.
hActCtx
==
NULL
,
"data.hActCtx=%p
\n
"
,
data
.
hActCtx
);
ok
(
data
.
ulAssemblyRosterIndex
==
exid
,
"data.ulAssemblyRosterIndex=%u, expected %u
\n
"
,
ok
_
(
__FILE__
,
line
)
(
data
.
hActCtx
==
NULL
,
"data.hActCtx=%p
\n
"
,
data
.
hActCtx
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulAssemblyRosterIndex
==
exid
,
"data.ulAssemblyRosterIndex=%u, expected %u
\n
"
,
data
.
ulAssemblyRosterIndex
,
exid
);
memset
(
&
data
,
0xfe
,
sizeof
(
data
));
...
...
@@ -801,25 +801,25 @@ static void test_find_window_class(HANDLE handle, LPCWSTR clsname, ULONG exid)
ret
=
pFindActCtxSectionStringW
(
FIND_ACTCTX_SECTION_KEY_RETURN_HACTCTX
,
NULL
,
ACTIVATION_CONTEXT_SECTION_WINDOW_CLASS_REDIRECTION
,
clsname
,
&
data
);
ok
(
ret
,
"FindActCtxSectionStringW failed: %u
\n
"
,
GetLastError
());
ok
_
(
__FILE__
,
line
)
(
ret
,
"FindActCtxSectionStringW failed: %u
\n
"
,
GetLastError
());
if
(
!
ret
)
{
skip
(
"couldn't find
\n
"
);
return
;
}
ok
(
data
.
cbSize
==
sizeof
(
data
),
"data.cbSize=%u
\n
"
,
data
.
cbSize
);
ok
(
data
.
ulDataFormatVersion
==
1
,
"data.ulDataFormatVersion=%u
\n
"
,
data
.
ulDataFormatVersion
);
ok
(
data
.
lpData
!=
NULL
,
"data.lpData == NULL
\n
"
);
/* ok(data.ulLength == ??, "data.ulLength=%u\n", data.ulLength); FIXME */
ok
(
data
.
lpSectionGlobalData
==
NULL
,
"data.lpSectionGlobalData != NULL
\n
"
);
ok
(
data
.
ulSectionGlobalDataLength
==
0
,
"data.ulSectionGlobalDataLength=%u
\n
"
,
ok
_
(
__FILE__
,
line
)
(
data
.
cbSize
==
sizeof
(
data
),
"data.cbSize=%u
\n
"
,
data
.
cbSize
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulDataFormatVersion
==
1
,
"data.ulDataFormatVersion=%u
\n
"
,
data
.
ulDataFormatVersion
);
ok
_
(
__FILE__
,
line
)
(
data
.
lpData
!=
NULL
,
"data.lpData == NULL
\n
"
);
/* ok
_(__FILE__, line)
(data.ulLength == ??, "data.ulLength=%u\n", data.ulLength); FIXME */
ok
_
(
__FILE__
,
line
)
(
data
.
lpSectionGlobalData
==
NULL
,
"data.lpSectionGlobalData != NULL
\n
"
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulSectionGlobalDataLength
==
0
,
"data.ulSectionGlobalDataLength=%u
\n
"
,
data
.
ulSectionGlobalDataLength
);
ok
(
data
.
lpSectionBase
!=
NULL
,
"data.lpSectionBase == NULL
\n
"
);
/* ok(data.ulSectionTotalLength == 0, "data.ulSectionTotalLength=%u\n",
ok
_
(
__FILE__
,
line
)
(
data
.
lpSectionBase
!=
NULL
,
"data.lpSectionBase == NULL
\n
"
);
/* ok
_(__FILE__, line)
(data.ulSectionTotalLength == 0, "data.ulSectionTotalLength=%u\n",
data.ulSectionTotalLength); FIXME */
ok
(
data
.
hActCtx
==
handle
,
"data.hActCtx=%p
\n
"
,
data
.
hActCtx
);
ok
(
data
.
ulAssemblyRosterIndex
==
exid
,
"data.ulAssemblyRosterIndex=%u, expected %u
\n
"
,
ok
_
(
__FILE__
,
line
)
(
data
.
hActCtx
==
handle
,
"data.hActCtx=%p
\n
"
,
data
.
hActCtx
);
ok
_
(
__FILE__
,
line
)
(
data
.
ulAssemblyRosterIndex
==
exid
,
"data.ulAssemblyRosterIndex=%u, expected %u
\n
"
,
data
.
ulAssemblyRosterIndex
,
exid
);
pReleaseActCtx
(
handle
);
...
...
@@ -863,7 +863,7 @@ static void test_find_string_fail(void)
}
static
void
test_basic_info
(
HANDLE
handle
)
static
void
test_basic_info
(
HANDLE
handle
,
int
line
)
{
ACTIVATION_CONTEXT_BASIC_INFORMATION
basic
;
SIZE_T
size
;
...
...
@@ -873,10 +873,10 @@ static void test_basic_info(HANDLE handle)
ActivationContextBasicInformation
,
&
basic
,
sizeof
(
basic
),
&
size
);
ok
(
b
,
"ActivationContextBasicInformation failed
\n
"
);
ok
(
size
==
sizeof
(
ACTIVATION_CONTEXT_BASIC_INFORMATION
),
"size mismatch
\n
"
);
ok
(
basic
.
dwFlags
==
0
,
"unexpected flags %x
\n
"
,
basic
.
dwFlags
);
ok
(
basic
.
hActCtx
==
handle
,
"unexpected handle
\n
"
);
ok
_
(
__FILE__
,
line
)
(
b
,
"ActivationContextBasicInformation failed
\n
"
);
ok
_
(
__FILE__
,
line
)
(
size
==
sizeof
(
ACTIVATION_CONTEXT_BASIC_INFORMATION
),
"size mismatch
\n
"
);
ok
_
(
__FILE__
,
line
)
(
basic
.
dwFlags
==
0
,
"unexpected flags %x
\n
"
,
basic
.
dwFlags
);
ok
_
(
__FILE__
,
line
)
(
basic
.
hActCtx
==
handle
,
"unexpected handle
\n
"
);
b
=
pQueryActCtxW
(
QUERY_ACTCTX_FLAG_USE_ACTIVE_ACTCTX
|
QUERY_ACTCTX_FLAG_NO_ADDREF
,
handle
,
NULL
,
...
...
@@ -884,18 +884,18 @@ static void test_basic_info(HANDLE handle)
sizeof
(
basic
),
&
size
);
if
(
handle
)
{
ok
(
!
b
,
"ActivationContextBasicInformation succeeded
\n
"
);
ok
(
size
==
0
,
"size mismatch
\n
"
);
ok
(
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"Wrong last error
\n
"
);
ok
(
basic
.
dwFlags
==
0
,
"unexpected flags %x
\n
"
,
basic
.
dwFlags
);
ok
(
basic
.
hActCtx
==
handle
,
"unexpected handle
\n
"
);
ok
_
(
__FILE__
,
line
)
(
!
b
,
"ActivationContextBasicInformation succeeded
\n
"
);
ok
_
(
__FILE__
,
line
)
(
size
==
0
,
"size mismatch
\n
"
);
ok
_
(
__FILE__
,
line
)
(
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"Wrong last error
\n
"
);
ok
_
(
__FILE__
,
line
)
(
basic
.
dwFlags
==
0
,
"unexpected flags %x
\n
"
,
basic
.
dwFlags
);
ok
_
(
__FILE__
,
line
)
(
basic
.
hActCtx
==
handle
,
"unexpected handle
\n
"
);
}
else
{
ok
(
b
,
"ActivationContextBasicInformation failed
\n
"
);
ok
(
size
==
sizeof
(
ACTIVATION_CONTEXT_BASIC_INFORMATION
),
"size mismatch
\n
"
);
ok
(
basic
.
dwFlags
==
0
,
"unexpected flags %x
\n
"
,
basic
.
dwFlags
);
ok
(
basic
.
hActCtx
==
handle
,
"unexpected handle
\n
"
);
ok
_
(
__FILE__
,
line
)
(
b
,
"ActivationContextBasicInformation failed
\n
"
);
ok
_
(
__FILE__
,
line
)
(
size
==
sizeof
(
ACTIVATION_CONTEXT_BASIC_INFORMATION
),
"size mismatch
\n
"
);
ok
_
(
__FILE__
,
line
)
(
basic
.
dwFlags
==
0
,
"unexpected flags %x
\n
"
,
basic
.
dwFlags
);
ok
_
(
__FILE__
,
line
)
(
basic
.
hActCtx
==
handle
,
"unexpected handle
\n
"
);
}
}
...
...
@@ -913,8 +913,8 @@ static void test_actctx(void)
ok
(
handle
==
NULL
,
"handle = %p, expected NULL
\n
"
,
handle
);
ok
(
b
,
"GetCurrentActCtx failed: %u
\n
"
,
GetLastError
());
if
(
b
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info0
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info0
,
__LINE__
);
pReleaseActCtx
(
handle
);
}
...
...
@@ -928,9 +928,9 @@ static void test_actctx(void)
handle
=
test_create
(
"test1.manifest"
,
manifest1
);
DeleteFileA
(
"test1.manifest"
);
if
(
handle
!=
INVALID_HANDLE_VALUE
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info1
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_info
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info1
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_info
,
__LINE__
);
if
(
pIsDebuggerPresent
&&
!
pIsDebuggerPresent
())
{
...
...
@@ -954,10 +954,10 @@ static void test_actctx(void)
DeleteFileA
(
"test2.manifest"
);
DeleteFileA
(
"testdep.manifest"
);
if
(
handle
!=
INVALID_HANDLE_VALUE
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info2
);
test_info_in_assembly
(
handle
,
1
,
&
manifest2_info
);
test_info_in_assembly
(
handle
,
2
,
&
depmanifest1_info
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info2
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest2_info
,
__LINE__
);
test_info_in_assembly
(
handle
,
2
,
&
depmanifest1_info
,
__LINE__
);
pReleaseActCtx
(
handle
);
}
...
...
@@ -972,17 +972,17 @@ static void test_actctx(void)
DeleteFileA
(
"test2-2.manifest"
);
DeleteFileA
(
"testdep.manifest"
);
if
(
handle
!=
INVALID_HANDLE_VALUE
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info2
);
test_info_in_assembly
(
handle
,
1
,
&
manifest2_info
);
test_info_in_assembly
(
handle
,
2
,
&
depmanifest2_info
);
test_file_info
(
handle
,
1
,
0
,
testlib_dll
);
test_file_info
(
handle
,
1
,
1
,
testlib2_dll
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info2
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest2_info
,
__LINE__
);
test_info_in_assembly
(
handle
,
2
,
&
depmanifest2_info
,
__LINE__
);
test_file_info
(
handle
,
1
,
0
,
testlib_dll
,
__LINE__
);
test_file_info
(
handle
,
1
,
1
,
testlib2_dll
,
__LINE__
);
b
=
pActivateActCtx
(
handle
,
&
cookie
);
ok
(
b
,
"ActivateActCtx failed: %u
\n
"
,
GetLastError
());
test_find_dll_redirection
(
handle
,
testlib_dll
,
2
);
test_find_dll_redirection
(
handle
,
testlib2_dll
,
2
);
test_find_dll_redirection
(
handle
,
testlib_dll
,
2
,
__LINE__
);
test_find_dll_redirection
(
handle
,
testlib2_dll
,
2
,
__LINE__
);
b
=
pDeactivateActCtx
(
0
,
cookie
);
ok
(
b
,
"DeactivateActCtx failed: %u
\n
"
,
GetLastError
());
...
...
@@ -1000,19 +1000,19 @@ static void test_actctx(void)
DeleteFileA
(
"test2-3.manifest"
);
DeleteFileA
(
"testdep.manifest"
);
if
(
handle
!=
INVALID_HANDLE_VALUE
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info2
);
test_info_in_assembly
(
handle
,
1
,
&
manifest2_info
);
test_info_in_assembly
(
handle
,
2
,
&
depmanifest3_info
);
test_file_info
(
handle
,
1
,
0
,
testlib_dll
);
test_file_info
(
handle
,
1
,
1
,
testlib2_dll
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info2
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest2_info
,
__LINE__
);
test_info_in_assembly
(
handle
,
2
,
&
depmanifest3_info
,
__LINE__
);
test_file_info
(
handle
,
1
,
0
,
testlib_dll
,
__LINE__
);
test_file_info
(
handle
,
1
,
1
,
testlib2_dll
,
__LINE__
);
b
=
pActivateActCtx
(
handle
,
&
cookie
);
ok
(
b
,
"ActivateActCtx failed: %u
\n
"
,
GetLastError
());
test_find_dll_redirection
(
handle
,
testlib_dll
,
2
);
test_find_dll_redirection
(
handle
,
testlib2_dll
,
2
);
test_find_window_class
(
handle
,
wndClassW
,
2
);
test_find_window_class
(
handle
,
wndClass2W
,
2
);
test_find_dll_redirection
(
handle
,
testlib_dll
,
2
,
__LINE__
);
test_find_dll_redirection
(
handle
,
testlib2_dll
,
2
,
__LINE__
);
test_find_window_class
(
handle
,
wndClassW
,
2
,
__LINE__
);
test_find_window_class
(
handle
,
wndClass2W
,
2
,
__LINE__
);
b
=
pDeactivateActCtx
(
0
,
cookie
);
ok
(
b
,
"DeactivateActCtx failed: %u
\n
"
,
GetLastError
());
...
...
@@ -1029,15 +1029,15 @@ static void test_actctx(void)
handle
=
test_create
(
"test3.manifest"
,
manifest3
);
DeleteFileA
(
"test3.manifest"
);
if
(
handle
!=
INVALID_HANDLE_VALUE
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info1
);
test_info_in_assembly
(
handle
,
1
,
&
manifest3_info
);
test_file_info
(
handle
,
0
,
0
,
testlib_dll
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info1
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest3_info
,
__LINE__
);
test_file_info
(
handle
,
0
,
0
,
testlib_dll
,
__LINE__
);
b
=
pActivateActCtx
(
handle
,
&
cookie
);
ok
(
b
,
"ActivateActCtx failed: %u
\n
"
,
GetLastError
());
test_find_dll_redirection
(
handle
,
testlib_dll
,
1
);
test_find_dll_redirection
(
handle
,
testlib_dll
,
1
);
test_find_dll_redirection
(
handle
,
testlib_dll
,
1
,
__LINE__
);
test_find_dll_redirection
(
handle
,
testlib_dll
,
1
,
__LINE__
);
test_find_string_fail
();
b
=
pDeactivateActCtx
(
0
,
cookie
);
ok
(
b
,
"DeactivateActCtx failed: %u
\n
"
,
GetLastError
());
...
...
@@ -1056,10 +1056,10 @@ static void test_actctx(void)
DeleteFileA
(
"test4.manifest"
);
DeleteFileA
(
"testdep.manifest"
);
if
(
handle
!=
INVALID_HANDLE_VALUE
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info2
);
test_info_in_assembly
(
handle
,
1
,
&
manifest4_info
);
test_info_in_assembly
(
handle
,
2
,
&
manifest_comctrl_info
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info2
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest4_info
,
__LINE__
);
test_info_in_assembly
(
handle
,
2
,
&
manifest_comctrl_info
,
__LINE__
);
pReleaseActCtx
(
handle
);
}
...
...
@@ -1075,9 +1075,9 @@ static void test_actctx(void)
handle
=
test_create
(
"..
\\
test1.manifest"
,
manifest1
);
DeleteFileA
(
"..
\\
test1.manifest"
);
if
(
handle
!=
INVALID_HANDLE_VALUE
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info1
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_info
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info1
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_info
,
__LINE__
);
pReleaseActCtx
(
handle
);
}
SetCurrentDirectoryW
(
work_dir
);
...
...
@@ -1095,9 +1095,9 @@ static void test_actctx(void)
handle
=
test_create
(
"test1.manifest"
,
manifest1
);
DeleteFileA
(
"test1.manifest"
);
if
(
handle
!=
INVALID_HANDLE_VALUE
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info1
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_info
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info1
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_info
,
__LINE__
);
pReleaseActCtx
(
handle
);
}
...
...
@@ -1110,9 +1110,9 @@ static void test_actctx(void)
handle
=
test_create
(
"test1.manifest"
,
manifest1
);
DeleteFileA
(
"test1.manifest"
);
if
(
handle
!=
INVALID_HANDLE_VALUE
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info1
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_info
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info1
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_info
,
__LINE__
);
pReleaseActCtx
(
handle
);
}
...
...
@@ -1129,9 +1129,9 @@ static void test_app_manifest(void)
ok
(
handle
==
NULL
,
"handle != NULL
\n
"
);
ok
(
b
,
"GetCurrentActCtx failed: %u
\n
"
,
GetLastError
());
if
(
b
)
{
test_basic_info
(
handle
);
test_detailed_info
(
handle
,
&
detailed_info1_child
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_child_info
);
test_basic_info
(
handle
,
__LINE__
);
test_detailed_info
(
handle
,
&
detailed_info1_child
,
__LINE__
);
test_info_in_assembly
(
handle
,
1
,
&
manifest1_child_info
,
__LINE__
);
pReleaseActCtx
(
handle
);
}
}
...
...
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