advapi32/tests: Add a test to cover second RegSetValueW Parameter (gcov)
André Hentschel
nerv at dawncrow.de
Tue Feb 14 13:35:09 CST 2012
Result of the example i wrote: wiki.winehq.org/CodeCoverage
see also http://source.winehq.org/patches/data/83629
---
dlls/advapi32/tests/registry.c | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/dlls/advapi32/tests/registry.c b/dlls/advapi32/tests/registry.c
index 60bc451..c0a7ebf 100644
--- a/dlls/advapi32/tests/registry.c
+++ b/dlls/advapi32/tests/registry.c
@@ -353,7 +353,12 @@ static void test_set_value(void)
test_hkey_main_Value_A(NULL, string1A, sizeof(string1A));
test_hkey_main_Value_W(NULL, string1W, sizeof(string1W));
- /* RegSetValueA ignores the size passed in */
+ ret = RegSetValueW(hkey_main, name1W, REG_SZ, string1W, sizeof(string1W));
+ ok(ret == ERROR_SUCCESS, "RegSetValueW failed: %d, GLE=%d\n", ret, GetLastError());
+ test_hkey_main_Value_A(name1A, string1A, sizeof(string1A));
+ test_hkey_main_Value_W(name1W, string1W, sizeof(string1W));
+
+ /* RegSetValueW ignores the size passed in */
ret = RegSetValueW(hkey_main, NULL, REG_SZ, string1W, 4 * sizeof(string1W[0]));
ok(ret == ERROR_SUCCESS, "RegSetValueW failed: %d, GLE=%d\n", ret, GetLastError());
test_hkey_main_Value_A(NULL, string1A, sizeof(string1A));
--
Best Regards, André Hentschel
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: Nachrichtenteil als Anhang
URL: <http://www.winehq.org/pipermail/wine-patches/attachments/20120214/1d34ac6f/attachment.ksh>
More information about the wine-patches
mailing list