aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoey Degges <jdegges@gmail.com>2021-01-04 21:08:42 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-01-05 23:14:30 +0000
commit1cd998c19101e3b093e81c126b3048c5d56058b0 (patch)
tree12945f8c4471d7865bdbcc28ca2fd25d21baff2a
parent137cfa13d5319bc91c3e5fe6c7062cb8c8484d64 (diff)
downloadbitbake-1cd998c19101e3b093e81c126b3048c5d56058b0.tar.gz
tests/fetch: Document behavior of test_gitfetch_usehead
The test `test_gitfetch_usehead' exercises a way to override the usehead feature by setting SRCREV. It may not be obvious that this is what is being exercised here so let's add some comments to document the expected behavior. Signed-off-by: Joey Degges <jdegges@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--lib/bb/tests/fetch.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/bb/tests/fetch.py b/lib/bb/tests/fetch.py
index 1323ac2cd..971c613dd 100644
--- a/lib/bb/tests/fetch.py
+++ b/lib/bb/tests/fetch.py
@@ -871,6 +871,10 @@ class FetcherNetworkTest(FetcherTest):
@skipIfNoNetwork()
def test_gitfetch_usehead(self):
+ # Since self.gitfetcher() sets SRCREV we expect this to override
+ # `usehead=1' and instead fetch the specified SRCREV. See
+ # test_local_gitfetch_usehead() for a positive use of the usehead
+ # feature.
url = "git://git.openembedded.org/bitbake;usehead=1"
self.assertRaises(bb.fetch.ParameterError, self.gitfetcher, url, url)