[llvm] [lldb][test] Mark gtest cases as XFAIL if the test is XFAIL (PR #102986)

via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 12 17:09:23 PDT 2024


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {darker}-->


:warning: Python code formatter, darker found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
darker --check --diff -r 0889809c706fd926b786bc2f8852646a17d7e21c...81f68a7a8e6cda5f32817c2779a60045b28830f6 llvm/utils/lit/lit/formats/googletest.py
``````````

</details>

<details>
<summary>
View the diff from darker here.
</summary>

``````````diff
--- googletest.py	2024-08-13 00:02:47.000000 +0000
+++ googletest.py	2024-08-13 00:08:45.015219 +0000
@@ -332,11 +332,15 @@
                         output = ""
                         if testinfo["result"] == "SKIPPED":
                             returnCode = lit.Test.SKIPPED
                         elif "failures" in testinfo:
                             has_failure_in_shard = True
-                            returnCode = lit.Test.XFAIL if test.isExpectedToFail() else lit.Test.FAIL
+                            returnCode = (
+                                lit.Test.XFAIL
+                                if test.isExpectedToFail()
+                                else lit.Test.FAIL
+                            )
                             output = header
                             for fail in testinfo["failures"]:
                                 output += fail["failure"] + "\n"
                         elif testinfo["result"] == "COMPLETED":
                             returnCode = lit.Test.PASS

``````````

</details>


https://github.com/llvm/llvm-project/pull/102986


More information about the llvm-commits mailing list