From: Hugh McMaster Subject: [PATCH] reg/tests: Remove embedded BOM tests and add other tests for 'reg import' Message-Id: Date: Sun, 28 Aug 2016 09:35:54 +0000 BOM may only appear at the start of the data stream. Use of an embedded BOM was deprecated in Unicode 3.2. Signed-off-by: Hugh McMaster --- programs/reg/tests/reg.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/programs/reg/tests/reg.c b/programs/reg/tests/reg.c index bd25a94..1dab72b 100644 --- a/programs/reg/tests/reg.c +++ b/programs/reg/tests/reg.c @@ -927,6 +927,18 @@ static void test_import(void) test_import_wstr("\xef\xbb\xbfREGEDIT4\n", &r); todo_wine ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); + test_import_wstr("\xef\xbb\xbf REGEDIT4\n", &r); + ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS) /* WinXP */, + "got exit code %d, expected 1\n", r); + + test_import_wstr("\xef\xbb\xbf\tREGEDIT4\n", &r); + ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS) /* WinXP */, + "got exit code %d, expected 1\n", r); + + test_import_wstr("\xef\xbb\xbf\nREGEDIT4\n", &r); + ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS) /* WinXP */, + "got exit code %d, expected 1\n", r); + test_import_wstr("\xef\xbb\xbfREGEDIT4\n" "[HKEY_CURRENT_USER\\" KEY_BASE "]\n", &r); todo_wine ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); @@ -971,18 +983,6 @@ static void test_import(void) ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS) /* WinXP */, "got exit code %d, expected 1\n", r); - test_import_wstr(" \xef\xbb\xbfWindows Registry Editor Version 5.00\n", &r); - ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS) /* WinXP */, - "got exit code %d, expected 1\n", r); - - test_import_wstr("\t\xef\xbb\xbfWindows Registry Editor Version 5.00\n", &r); - ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS) /* WinXP */, - "got exit code %d, expected 1\n", r); - - test_import_wstr("\n\xef\xbb\xbfWindows Registry Editor Version 5.00\n", &r); - ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS) /* WinXP */, - "got exit code %d, expected 1\n", r); - test_import_wstr("\xef\xbb\xbf Windows Registry Editor Version 5.00\n", &r); todo_wine ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); -- 2.7.4