[all-commits] [llvm/llvm-project] 5b3861: [lldb][test] Switch LLDB API tests from vendored u...
Jordan Rupprecht via All-commits
all-commits at lists.llvm.org
Tue Feb 13 14:19:53 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 5b386158aacac4b41126983a5379d36ed413d0ea
https://github.com/llvm/llvm-project/commit/5b386158aacac4b41126983a5379d36ed413d0ea
Author: Jordan Rupprecht <rupprecht at google.com>
Date: 2024-02-13 (Tue, 13 Feb 2024)
Changed paths:
M lldb/packages/Python/lldbsuite/test/configuration.py
M lldb/packages/Python/lldbsuite/test/decorators.py
M lldb/packages/Python/lldbsuite/test/dotest.py
M lldb/packages/Python/lldbsuite/test/lldbtest.py
M lldb/packages/Python/lldbsuite/test/test_result.py
M lldb/test/API/commands/expression/test/TestExprs.py
M lldb/test/API/functionalities/breakpoint/thread_plan_user_breakpoint/TestThreadPlanUserBreakpoint.py
M lldb/test/API/functionalities/jitloader_gdb/TestJITLoaderGDB.py
M lldb/test/API/functionalities/thread/state/TestThreadStates.py
M lldb/test/API/functionalities/tty/TestTerminal.py
M lldb/test/API/lang/c/shared_lib/TestSharedLib.py
M lldb/test/API/lang/c/shared_lib_stripped_symbols/TestSharedLibStrippedSymbols.py
M lldb/test/API/lang/cpp/namespace/TestNamespaceLookup.py
M lldb/test/API/lang/cpp/reference-to-outer-type/TestCppReferenceToOuterClass.py
M lldb/test/API/lang/cpp/thread_local/TestThreadLocal.py
M lldb/test/API/lang/objc/hidden-ivars/TestHiddenIvars.py
M lldb/test/API/lldbtest.py
M lldb/test/API/macosx/universal/TestUniversal.py
M lldb/test/API/tools/lldb-server/libraries-svr4/TestGdbRemoteLibrariesSvr4Support.py
M lldb/test/API/tools/lldb-server/test/test_lldbgdbserverutils.py
Log Message:
-----------
[lldb][test] Switch LLDB API tests from vendored unittest2 to unittest (#79945)
This removes the dependency LLDB API tests have on
lldb/third_party/Python/module/unittest2, and instead uses the standard
one provided by Python.
This does not actually remove the vendored dep yet, nor update the docs.
I'll do both those once this sticks.
Non-trivial changes to call out:
- expected failures (i.e. "bugnumber") don't have a reason anymore, so
those params were removed
- `assertItemsEqual` is now called `assertCountEqual`
- When a test is marked xfail, our copy of unittest2 considers failures
during teardown to be OK, but modern unittest does not. See
TestThreadLocal.py. (Very likely could be a real bug/leak).
- Our copy of unittest2 was patched to print all test results, even ones
that don't happen, e.g. `(5 passes, 0 failures, 1 errors, 0 skipped,
...)`, but standard unittest prints a terser message that omits test
result types that didn't happen, e.g. `OK (skipped=1)`. Our lit
integration parses this stderr and needs to be updated w/ that
expectation.
I tested this w/ `ninja check-lldb-api` on Linux. There's a good chance
non-Linux tests have similar quirks, but I'm not able to uncover those.
More information about the All-commits
mailing list