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
51743827
Commit
51743827
authored
May 26, 2017
by
Hugh McMaster
Committed by
Alexandre Julliard
May 26, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
regedit/tests: Add tests for importing Windows 3.1 registry data.
Signed-off-by:
Hugh McMaster
<
hugh.mcmaster@outlook.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
3fef1e1c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
50 additions
and
0 deletions
+50
-0
regedit.c
programs/regedit/tests/regedit.c
+50
-0
No files found.
programs/regedit/tests/regedit.c
View file @
51743827
...
...
@@ -759,6 +759,55 @@ static void test_invalid_import(void)
ok
(
lr
==
ERROR_SUCCESS
,
"RegDeleteKeyA failed: %d
\n
"
,
lr
);
}
static
void
test_invalid_import_31
(
void
)
{
HKEY
hkey
;
LONG
lr
;
lr
=
RegCreateKeyExA
(
HKEY_CLASSES_ROOT
,
KEY_BASE
,
0
,
NULL
,
REG_OPTION_NON_VOLATILE
,
KEY_READ
,
NULL
,
&
hkey
,
NULL
);
ok
(
lr
==
ERROR_SUCCESS
,
"RegCreateKeyExA failed: %d
\n
"
,
lr
);
/* Test character validity at the start of the line */
exec_import_str
(
"REGEDIT
\r\n
"
" HKEY_CLASSES_ROOT
\\
"
KEY_BASE
" = Value1a
\r\n
"
);
todo_wine
verify_reg_nonexist
(
hkey
,
""
);
exec_import_str
(
"REGEDIT
\r\n
"
" HKEY_CLASSES_ROOT
\\
"
KEY_BASE
" = Value1b
\r\n
"
);
todo_wine
verify_reg_nonexist
(
hkey
,
""
);
exec_import_str
(
"REGEDIT
\r\n
"
"
\t
HKEY_CLASSES_ROOT
\\
"
KEY_BASE
" = Value1c
\r\n
"
);
todo_wine
verify_reg_nonexist
(
hkey
,
""
);
exec_import_str
(
"REGEDIT
\r\n
"
";HKEY_CLASSES_ROOT
\\
"
KEY_BASE
" = Value2a
\r\n
"
);
todo_wine
verify_reg_nonexist
(
hkey
,
""
);
exec_import_str
(
"REGEDIT
\r\n
"
"#HKEY_CLASSES_ROOT
\\
"
KEY_BASE
" = Value2b
\r\n
"
);
todo_wine
verify_reg_nonexist
(
hkey
,
""
);
/* Test case sensitivity */
exec_import_str
(
"REGEDIT
\r\n
"
"hkey_classes_root
\\
"
KEY_BASE
" = Value3a
\r\n
"
);
todo_wine
verify_reg_nonexist
(
hkey
,
""
);
exec_import_str
(
"REGEDIT
\r\n
"
"hKEY_CLASSES_ROOT
\\
"
KEY_BASE
" = Value3b
\r\n
"
);
todo_wine
verify_reg_nonexist
(
hkey
,
""
);
exec_import_str
(
"REGEDIT
\r\n
"
"Hkey_Classes_Root
\\
"
KEY_BASE
" = Value3c
\r\n
"
);
todo_wine
verify_reg_nonexist
(
hkey
,
""
);
RegCloseKey
(
hkey
);
lr
=
RegDeleteKeyA
(
HKEY_CLASSES_ROOT
,
KEY_BASE
);
ok
(
lr
==
ERROR_SUCCESS
,
"RegDeleteKeyA failed: %d
\n
"
,
lr
);
}
static
void
test_comments
(
void
)
{
LONG
lr
;
...
...
@@ -1077,6 +1126,7 @@ START_TEST(regedit)
test_basic_import
();
test_basic_import_31
();
test_invalid_import
();
test_invalid_import_31
();
test_comments
();
test_import_with_whitespace
();
}
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