Skip to content
Commit 50d9ed5c authored by Grzegorz Swiderski's avatar Grzegorz Swiderski Committed by Benjamin Cabé
Browse files

scripts: ci: check_compliance: Update KconfigCheck subclassing



So far, the behavior of different Kconfig checks has been parametrized
using the `run()` method, and every new check has introduced with it a
new argument to that method.

It's possible to replace each `run()` argument by way of overriding
different class methods and making better use of inheritance:

    free=False          Stub check_no_undef_outside_kconfig()
    no_modules=True     Stub get_modules()
    filename            Introduce class member FILENAME
    hwm                 (unused)

This should establish a more scalable and straightforward pattern for
adding future Kconfig checks. It also favors composability, which will
come in handy when implementing checks for sysbuild Kconfig.

Additionally, avoid duplicating `doc` and `path_hint` in every subclass.

Signed-off-by: default avatarGrzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
parent 17ba4795
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment