From: Simon Glass Date: Mon, 13 Nov 2017 04:52:22 +0000 (-0700) Subject: binman: Add a main program to the tests X-Git-Tag: v2018.01-rc1~69^2~7 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=9fc60b4975b14da3693f3dd86378fb918ea13f41;p=u-boot binman: Add a main program to the tests Add a main program so that the tests can be executed directly, without going through the main binman program. Signed-off-by: Simon Glass --- diff --git a/tools/binman/entry_test.py b/tools/binman/entry_test.py index 789b26fd9f..caa523ebf8 100644 --- a/tools/binman/entry_test.py +++ b/tools/binman/entry_test.py @@ -55,3 +55,7 @@ class TestEntry(unittest.TestCase): entry.Entry.Create(None, node, node.name) self.assertIn("Unknown entry type 'invalid-name' in node " "'invalid-path'", str(e.exception)) + + +if __name__ == "__main__": + unittest.main() diff --git a/tools/binman/ftest.py b/tools/binman/ftest.py index eae1ab1c4b..539ebc57f5 100644 --- a/tools/binman/ftest.py +++ b/tools/binman/ftest.py @@ -813,3 +813,7 @@ class TestFunctional(unittest.TestCase): """Test that an image with a VBT binary can be created""" data = self._DoReadFile('46_intel-vbt.dts') self.assertEqual(VBT_DATA, data[:len(VBT_DATA)]) + + +if __name__ == "__main__": + unittest.main()