================ @@ -914,6 +914,25 @@ def checkForkVForkSupport(): configuration.skip_categories.append("fork") +def checkPexpectSupport(): + from lldbsuite.test import lldbplatformutil + + platform = lldbplatformutil.getPlatform() + + # llvm.org/pr22274: need a pexpect replacement for windows + if platform in ["windows"]: + if configuration.verbose: + print("pexpect tests will be skipped because of unsupported platform") + configuration.skip_categories.append("pexpect") + elif not configuration.shouldSkipBecauseOfCategories(["pexpect"]): + try: + import pexpect + except: + print( + "Warning: pexpect is not installed, but pexpect tests are not being skipped." ---------------- rupprecht wrote:
For a pexpect test, it would fail either way, but raising an error here would be more clear about the failure. For a non-pexpect test, this will unnecessarily fail. `ninja check-lldb-api` will have ~1k test failures instead of ~30 failures. Updated to `raise` instead here. https://github.com/llvm/llvm-project/pull/84860 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits