]> git.baikalelectronics.ru Git - kernel.git/commitdiff
kunit: tool: Fix a python tuple typing error
authorDavid Gow <davidgow@google.com>
Tue, 23 Feb 2021 05:49:30 +0000 (21:49 -0800)
committerShuah Khan <skhan@linuxfoundation.org>
Thu, 11 Mar 2021 21:37:37 +0000 (14:37 -0700)
The first argument to namedtuple() should match the name of the type,
which wasn't the case for KconfigEntryBase.

Fixing this is enough to make mypy show no python typing errors again.

Fixes 58cf1310a6 ("kunit: kunit_tool: Allow .kunitconfig to disable config items")
Signed-off-by: David Gow <davidgow@google.com>
Reviewed-by: Daniel Latypov <dlatypov@google.com>
Acked-by: Brendan Higgins <brendanhiggins@google.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
tools/testing/kunit/kunit_config.py

index 0b550cbd667d1ea36aaa16c3c2d4ff1ba4a6679f..1e2683dcc0e7a987b90f295eb4342b5731ff3bf9 100644 (file)
@@ -13,7 +13,7 @@ from typing import List, Set
 CONFIG_IS_NOT_SET_PATTERN = r'^# CONFIG_(\w+) is not set$'
 CONFIG_PATTERN = r'^CONFIG_(\w+)=(\S+|".*")$'
 
-KconfigEntryBase = collections.namedtuple('KconfigEntry', ['name', 'value'])
+KconfigEntryBase = collections.namedtuple('KconfigEntryBase', ['name', 'value'])
 
 class KconfigEntry(KconfigEntryBase):