[U-Boot] [PATCH v2 2/2] test/py: add test for whitelist of variables while importing environment
Simon Glass
sjg at chromium.org
Tue May 22 23:29:56 UTC 2018
On 18 May 2018 at 08:45, Quentin Schulz <quentin.schulz at bootlin.com> wrote:
> This tests that the importing of an environment with a specified
> whitelist works as intended.
>
> If the variable whitelisted_vars is not set, the env importing should
> fail with a given message.
>
> For each variable separated by spaces in whitelisted_vars, if
> - foo is bar in current env and bar2 in exported env, after importing
> exported env, foo shall be bar2,
> - foo does not exist in current env and foo is bar2 in exported env,
> after importing exported env, foo shall be bar2,
> - foo is bar in current env and does not exist in exported env (but is
> in the whitelisted_vars), after importing exported env, foo shall be
> empty,
>
> Any variable not in whitelisted_vars should be left untouched.
>
> Signed-off-by: Quentin Schulz <quentin.schulz at bootlin.com>
> ---
>
> added in v2
>
> test/py/tests/test_env.py | 40 ++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 40 insertions(+)
Reviewed-by: Simon Glass <sjg at chromium.org>
More information about the U-Boot
mailing list