[RESEND PATCH 2/3] selftests: fix condition in run_tests