On Fri, Nov 5, 2021 at 9:31 PM 'Daniel Latypov' via KUnit Development kunit-dev@googlegroups.com wrote:
read_from_file() clears its `self` Kconfig object and parses a config file.
It is a way to construct Kconfig objects more so than an operation on Kconfig objects. This is reflected in the fact its only ever used as: kconfig = kunit_config.Kconfig() kconfig.read_from_file(path)
So clean this up and simplify callers by replacing it with kconfig = kunit_config.parse_file(path)
Do the same thing for the related parse_from_string() function as well.
Signed-off-by: Daniel Latypov dlatypov@google.com
Reviewed-by: Brendan Higgins brendanhiggins@google.com