unit-test: Rename 'pkg' parameter of build_dep_tree()
A Package class will be introduced shortly. Clarify the intent of the
variable name.
Change-Id: I8bb97a7ecbb3c003dfb1cadff9dc428504272ac6
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
diff --git a/scripts/unit-test.py b/scripts/unit-test.py
index 75d4e8e..1572c75 100755
--- a/scripts/unit-test.py
+++ b/scripts/unit-test.py
@@ -449,15 +449,15 @@
check_call_cmd(*make_parallel)
check_call_cmd('sudo', '-n', '--', *(make_parallel + [ 'install' ]))
-def build_dep_tree(pkg, pkgdir, dep_added, head, branch, dep_tree=None):
+def build_dep_tree(name, pkgdir, dep_added, head, branch, dep_tree=None):
"""
- For each package(pkg), starting with the package to be unit tested,
+ For each package (name), starting with the package to be unit tested,
parse its 'configure.ac' file from within the package's directory(pkgdir)
for each package dependency defined recursively doing the same thing
on each package found as a dependency.
Parameter descriptions:
- pkg Name of the package
+ name Name of the package
pkgdir Directory where package source is located
dep_added Current dict of dependencies and added status
head Head node of the dependency tree
@@ -499,10 +499,10 @@
continue
else:
# Cyclic dependency failure
- raise Exception("Cyclic dependencies found in "+pkg)
+ raise Exception("Cyclic dependencies found in "+name)
- if not dep_added[pkg]:
- dep_added[pkg] = True
+ if not dep_added[name]:
+ dep_added[name] = True
return dep_added