u-boot-brain/test/py/tests
Stephen Warren fc1a3bfedf test_env: don't strip() printenv results
get_env() was originally written to strip() the output of printenv to
isolate the test from any whitespace changes in printenv's output.
However, this throws away any whitespace in the variable value, which can
cause issues when test code expects to see that whitespace. In fact,
printenv never adds any whitespace at all, so there's no need to strip.

The strip causes a practical problem for test_env_echo_exists() if
state_test_env.get_existent_var() happens to choose a U-Boot variable that
contains trailing whitespace. This is true for variable boot_targets.

With Python 2, get_existent_var() never returned boot_targets so this
issue never caused a practical problem.

With Python 3, get_existent_var does sometimes return boot_targets, no
doubt due to Python 3's different dict hash key order implementation,
about 0.5-2% of the time, so this test appears intermittent. With the
strip removed, this intermittency is solved, since the test passes for all
possible U-Boot variables.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
2020-01-02 10:27:23 -05:00
..
test_android test/py: Split mark to multiple lines 2019-10-30 17:48:46 -04:00
test_fs test/py: test_fs: add tests for creating/deleting many files 2019-12-05 10:28:38 -05:00
vboot pytest: vboot: add a test for required key 2019-10-15 08:40:02 -06:00
test_000_version.py SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
test_bind.py test/py: Use raw strings more to avoid deprecation warnings 2019-10-30 17:48:47 -04:00
test_dfu.py test: Use single quote consistently 2019-01-15 15:28:41 -05:00
test_efi_loader.py test: Use single quote consistently 2019-01-15 15:28:41 -05:00
test_efi_selftest.py test/py: test_efi_selftest.py: Updates for python 3 support 2019-10-30 17:48:47 -04:00
test_env.py test_env: don't strip() printenv results 2020-01-02 10:27:23 -05:00
test_fit.py test/py: Manual python3 fixes 2019-10-30 17:48:47 -04:00
test_fpga.py test/py: Automated conversion to Python 3 2019-10-30 17:48:47 -04:00
test_gpt.py test/py: gpt: Use long options for sgdisk 2019-07-18 11:31:26 -04:00
test_handoff.py spl: Add support for passing handoff info to U-Boot proper 2018-11-26 08:25:37 -05:00
test_help.py SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
test_hush_if_test.py test/py: hush_if_test: Use open() in place of file() 2018-07-10 14:50:50 -06:00
test_log.py test/py: Automated conversion to Python 3 2019-10-30 17:48:47 -04:00
test_md.py SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
test_mmc_rd.py test/py: don't use mmc_rd config for other mmc tests 2019-05-09 19:52:55 -04:00
test_mmc_wr.py test/py: Automated conversion to Python 3 2019-10-30 17:48:47 -04:00
test_net.py test/py: use default load address for tftp 2019-02-12 07:19:24 -05:00
test_ofplatdata.py test: check u-boot properties in SPL device tree 2019-07-10 16:52:58 -06:00
test_pinmux.py test/py: test pinmux command 2018-11-16 16:51:57 -05:00
test_sandbox_exit.py SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
test_sf.py SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
test_shell_basics.py SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
test_sleep.py SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
test_tpm2.py test/py: tpm2: switch from 'tpm' to 'tpm2' command 2018-07-28 11:58:08 -04:00
test_ums.py test: Use single quote consistently 2019-01-15 15:28:41 -05:00
test_unknown_cmd.py SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
test_ut.py test/py: test_ut.py: Ensure we use bytes 2019-10-30 17:48:47 -04:00
test_vboot.py pytest: vboot: add a test for required key 2019-10-15 08:40:02 -06:00