Commit 170c966c authored by Laura Nao's avatar Laura Nao Committed by Shuah Khan
Browse files

selftests: ksft: Fix finished() helper exit code on skipped tests



The Python finished() helper currently exits with KSFT_FAIL when there
are only passed and skipped tests. Fix the logic to exit with KSFT_PASS
instead, making it consistent with its C and bash counterparts
(ksft_finished() and ktap_finished() respectively).

Reviewed-by: default avatarNícolas F. R. A. Prado <nfraprado@collabora.com>
Fixes: dacf1d7a ("kselftest: Add test to verify probe of devices from discoverable buses")
Signed-off-by: default avatarLaura Nao <laura.nao@collabora.com>
Reviewed-by: default avatarMuhammad Usama Anjum <usama.anjum@collabora.com>
Signed-off-by: default avatarShuah Khan <skhan@linuxfoundation.org>
parent 8400291e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -70,7 +70,7 @@ def test_result(condition, description=""):


def finished():
    if ksft_cnt["pass"] == ksft_num_tests:
    if ksft_cnt["pass"] + ksft_cnt["skip"] == ksft_num_tests:
        exit_code = KSFT_PASS
    else:
        exit_code = KSFT_FAIL