From c886a786cf63e4e19f004c2d8853c859ba5b938a Mon Sep 17 00:00:00 2001 From: Olof Johansson Date: Tue, 19 Jan 2016 16:04:11 +0100 Subject: bitbake: tests/codeparser.py: Add filename/lineno flags to test variable A recent change in bitbake added filename/lineno information to the parameters of bb.data.build_dependencies(). The codeparser tests required a little adaption to the changes, adding the flags to the FOO variable used in the tests. The error seen when running the tests is a TypeError exception raised in bb.codeparser: TypeError: int() argument must be a string or a number, not 'NoneType' (Bitbake rev: f1fe674397ac5cd355696d5b4cc90b7cfa6c867f) Signed-off-by: Olof Johansson Signed-off-by: Richard Purdie --- bitbake/lib/bb/tests/codeparser.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'bitbake') diff --git a/bitbake/lib/bb/tests/codeparser.py b/bitbake/lib/bb/tests/codeparser.py index 4454bc51ed..bb820e4037 100644 --- a/bitbake/lib/bb/tests/codeparser.py +++ b/bitbake/lib/bb/tests/codeparser.py @@ -293,7 +293,12 @@ bb.data.getVar(a(), d, False) def test_python(self): self.d.setVar("FOO", self.pydata) self.setEmptyVars(["inexpand", "a", "test2", "test"]) - self.d.setVarFlags("FOO", {"func": True, "python": True}) + self.d.setVarFlags("FOO", { + "func": True, + "python": True, + "lineno": 1, + "filename": "example.bb", + }) deps, values = bb.data.build_dependencies("FOO", set(self.d.keys()), set(), set(), self.d) -- cgit v1.2.3-54-g00ecf