From: Patrick DELAUNAY Date: Tue, 11 Feb 2020 09:20:48 +0000 Subject: [PATCH v2 7/7] test: env: add test for env info sub-command In-Reply-To: <4b5a447b-0d0f-2a34-033a-c34bdc89afcf@wwwdotorg.org> References: <20200210170129.8405-1-patrick.delaunay@st.com> <20200210170129.8405-6-patrick.delaunay@st.com> <4b5a447b-0d0f-2a34-033a-c34bdc89afcf@wwwdotorg.org> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: u-boot@lists.denx.de Hi Stephen > From: Stephen Warren > Sent: lundi 10 f=C3=A9vrier 2020 21:25 >=20 > On 2/10/20 10:01 AM, Patrick Delaunay wrote: > > Add a pytest for testing the env info sub-command: > > > > test_env_info: test command with several option > > > > test_env_info_test: test the result of the sub-commandi with quiet > > option, >=20 > Nit: Remove "i" from the end of "sub-commandi". yes =20 > > diff --git a/test/py/tests/test_env.py b/test/py/tests/test_env.py >=20 > > + at pytest.mark.boardspec('sandbox') >=20 > I assume that's just so things like "environment can't be persisted" can = be > guaranteed, since other boards will be different to sandbox here? Yes. And also the test is based on command "env_loc" (select the env backend us= ed) which is sandbox specific. So this test will failed on real platform. =20 > > + at pytest.mark.buildconfigspec('cmd_nvedit_info') > > + at pytest.mark.buildconfigspec('cmd_echo') > > +def test_env_info_test(state_test_env): > > + > > + """Test 'env info' quiet command result with several options for t= est. > > + """ >=20 > Nit: It took me a while to realized what the "for test" and "_test" > function name suffix meant. Perhaps _retcode might be a better function n= ame > suffix? ok =20 > Acked-by: Stephen Warren