Commit 0f7bae5a authored by Lei Zhang's avatar Lei Zhang Committed by Alexandre Julliard

userenv: Add a test for variable inheritance for CreateEnvironmentBlock.

parent bf02fa30
...@@ -186,6 +186,9 @@ static void test_create_env(void) ...@@ -186,6 +186,9 @@ static void test_create_env(void)
{ 0, { 0, 0, 0, 0 } } { 0, { 0, 0, 0, 0 } }
}; };
r = SetEnvironmentVariableA("WINE_XYZZY", "ZZYZX");
expect(TRUE, r);
r = CreateEnvironmentBlock(NULL, NULL, FALSE); r = CreateEnvironmentBlock(NULL, NULL, FALSE);
expect(FALSE, r); expect(FALSE, r);
...@@ -268,6 +271,15 @@ static void test_create_env(void) ...@@ -268,6 +271,15 @@ static void test_create_env(void)
expect_env(TRUE, r, htok_vars[i].name); expect_env(TRUE, r, htok_vars[i].name);
i++; i++;
} }
r = get_env(env1, "WINE_XYZZY", &st);
expect(FALSE, r);
r = get_env(env2, "WINE_XYZZY", &st);
expect(FALSE, r);
r = get_env(env3, "WINE_XYZZY", &st);
expect(TRUE, r);
r = get_env(env4, "WINE_XYZZY", &st);
expect(TRUE, r);
} }
START_TEST(userenv) START_TEST(userenv)
......
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