Commit 18182676 authored by Hugh McMaster's avatar Hugh McMaster Committed by Alexandre Julliard

reg/tests: Test capitalisation of switches.

parent 85349354
...@@ -227,6 +227,12 @@ static void test_add(void) ...@@ -227,6 +227,12 @@ static void test_add(void)
run_reg_exe("reg add /?", &r); run_reg_exe("reg add /?", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg add /h", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg add -H", &r);
todo_wine ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
err = RegDeleteKeyA(HKEY_CURRENT_USER, KEY_BASE); err = RegDeleteKeyA(HKEY_CURRENT_USER, KEY_BASE);
ok(err == ERROR_SUCCESS || err == ERROR_FILE_NOT_FOUND, "got %d\n", err); ok(err == ERROR_SUCCESS || err == ERROR_FILE_NOT_FOUND, "got %d\n", err);
...@@ -608,6 +614,12 @@ static void test_delete(void) ...@@ -608,6 +614,12 @@ static void test_delete(void)
run_reg_exe("reg delete /?", &r); run_reg_exe("reg delete /?", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg delete /h", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg delete -H", &r);
todo_wine ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
add_key(HKEY_CURRENT_USER, KEY_BASE, &hkey); add_key(HKEY_CURRENT_USER, KEY_BASE, &hkey);
add_value(hkey, "foo", REG_DWORD, &deadbeef, sizeof(deadbeef)); add_value(hkey, "foo", REG_DWORD, &deadbeef, sizeof(deadbeef));
add_value(hkey, "bar", REG_DWORD, &deadbeef, sizeof(deadbeef)); add_value(hkey, "bar", REG_DWORD, &deadbeef, sizeof(deadbeef));
...@@ -660,6 +672,12 @@ static void test_query(void) ...@@ -660,6 +672,12 @@ static void test_query(void)
run_reg_exe("reg query /?", &r); run_reg_exe("reg query /?", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg query /h", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg query -H", &r);
todo_wine ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
/* Create a test key */ /* Create a test key */
add_key(HKEY_CURRENT_USER, KEY_BASE, &key); add_key(HKEY_CURRENT_USER, KEY_BASE, &key);
...@@ -848,6 +866,12 @@ static void test_import(void) ...@@ -848,6 +866,12 @@ static void test_import(void)
run_reg_exe("reg import /?", &r); run_reg_exe("reg import /?", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg import /h", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg import -H", &r);
todo_wine ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg import missing.reg", &r); run_reg_exe("reg import missing.reg", &r);
ok(r == REG_EXIT_FAILURE, "got exit code %d, expected 1\n", r); ok(r == REG_EXIT_FAILURE, "got exit code %d, expected 1\n", r);
...@@ -4391,6 +4415,12 @@ static void test_export(void) ...@@ -4391,6 +4415,12 @@ static void test_export(void)
run_reg_exe("reg export /?", &r); run_reg_exe("reg export /?", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg export /h", &r);
ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg export -H", &r);
todo_wine ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r);
run_reg_exe("reg export \\\\remote-pc\\HKLM\\Wine file.reg", &r); run_reg_exe("reg export \\\\remote-pc\\HKLM\\Wine file.reg", &r);
ok(r == REG_EXIT_FAILURE, "got exit code %d, expected 1\n", r); ok(r == REG_EXIT_FAILURE, "got exit code %d, expected 1\n", r);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment