[all-commits] [llvm/llvm-project] 9c2468: [lldb][test] Modernize asserts (#82503)

Jordan Rupprecht via All-commits all-commits at lists.llvm.org
Wed Feb 21 11:02:43 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9c2468821ec51defd09c246fea4a47886fff8c01
      https://github.com/llvm/llvm-project/commit/9c2468821ec51defd09c246fea4a47886fff8c01
  Author: Jordan Rupprecht <rupprecht at google.com>
  Date:   2024-02-21 (Wed, 21 Feb 2024)

  Changed paths:
    M lldb/test/API/commands/expression/call-restarts/TestCallThatRestarts.py
    M lldb/test/API/commands/expression/call-throws/TestCallThatThrows.py
    M lldb/test/API/commands/expression/completion-crash-invalid-iterator/TestInvalidIteratorCompletionCrash.py
    M lldb/test/API/commands/expression/fixits/TestFixIts.py
    M lldb/test/API/commands/expression/test/TestExprs.py
    M lldb/test/API/commands/expression/unwind_expression/TestUnwindExpression.py
    M lldb/test/API/commands/register/register/aarch64_sme_z_registers/save_restore/TestSMEZRegistersSaveRestore.py
    M lldb/test/API/commands/register/register/aarch64_sme_z_registers/za_dynamic_resize/TestZAThreadedDynamic.py
    M lldb/test/API/commands/register/register/aarch64_sve_registers/rw_access_dynamic_resize/TestSVEThreadedDynamic.py
    M lldb/test/API/commands/session/save/TestSessionSave.py
    M lldb/test/API/commands/statistics/basic/TestStats.py
    M lldb/test/API/commands/trace/TestTraceExport.py
    M lldb/test/API/commands/trace/TestTraceSave.py
    M lldb/test/API/commands/trace/multiple-threads/TestTraceStartStopMultipleThreads.py
    M lldb/test/API/functionalities/archives/TestBSDArchives.py
    M lldb/test/API/functionalities/asan/TestMemoryHistory.py
    M lldb/test/API/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py
    M lldb/test/API/functionalities/breakpoint/breakpoint_command/TestBreakpointCommandsFromPython.py
    M lldb/test/API/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py
    M lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py
    M lldb/test/API/functionalities/breakpoint/objc/TestObjCBreakpoints.py
    M lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py
    M lldb/test/API/functionalities/breakpoint/serialize/TestBreakpointSerialization.py
    M lldb/test/API/functionalities/breakpoint/step_over_breakpoint/TestStepOverBreakpoint.py
    M lldb/test/API/functionalities/data-formatter/data-formatter-python-synth/TestDataFormatterPythonSynth.py
    M lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/string/TestDataFormatterLibcxxString.py
    M lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/string_view/TestDataFormatterLibcxxStringView.py
    M lldb/test/API/functionalities/gdb_remote_client/TestMSP430MSPDebug.py
    M lldb/test/API/functionalities/multidebugger_commands/TestMultipleDebuggersCommands.py
    M lldb/test/API/functionalities/process_save_core_minidump/TestProcessSaveCoreMinidump.py
    M lldb/test/API/functionalities/return-value/TestReturnValue.py
    M lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py
    M lldb/test/API/functionalities/signal/TestSendSignal.py
    M lldb/test/API/functionalities/signal/handle-abrt/TestHandleAbort.py
    M lldb/test/API/functionalities/signal/handle-segv/TestHandleSegv.py
    M lldb/test/API/functionalities/signal/raise/TestRaise.py
    M lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py
    M lldb/test/API/functionalities/step-avoids-regexp/TestStepAvoidsRegexp.py
    M lldb/test/API/functionalities/target-new-solib-notifications/TestModuleLoadedNotifys.py
    M lldb/test/API/functionalities/thread/break_after_join/TestBreakAfterJoin.py
    M lldb/test/API/functionalities/thread/create_during_step/TestCreateDuringStep.py
    M lldb/test/API/functionalities/thread/exit_during_break/TestExitDuringBreak.py
    M lldb/test/API/functionalities/thread/multi_break/TestMultipleBreakpoints.py
    M lldb/test/API/functionalities/thread/num_threads/TestNumThreads.py
    M lldb/test/API/functionalities/thread_plan/TestThreadPlanCommands.py
    M lldb/test/API/functionalities/tsan/basic/TestTsanBasic.py
    M lldb/test/API/functionalities/tsan/multiple/TestTsanMultiple.py
    M lldb/test/API/functionalities/unwind/aarch64_unwind_pac/TestAArch64UnwindPAC.py
    M lldb/test/API/lang/c/register_variables/TestRegisterVariables.py
    M lldb/test/API/lang/c/stepping/TestStepAndBreakpoints.py
    M lldb/test/API/lang/cpp/dynamic-value/TestDynamicValue.py
    M lldb/test/API/lang/cpp/namespace/TestNamespace.py
    M lldb/test/API/lang/cpp/stl/TestSTL.py
    M lldb/test/API/lang/objc/foundation/TestFoundationDisassembly.py
    M lldb/test/API/lang/objc/objc-class-method/TestObjCClassMethod.py
    M lldb/test/API/lang/objc/objc-struct-argument/TestObjCStructArgument.py
    M lldb/test/API/lang/objc/objc-struct-return/TestObjCStructReturn.py
    M lldb/test/API/lang/objc/objc-super/TestObjCSuper.py
    M lldb/test/API/lang/objc/rdar-12408181/TestRdar12408181.py
    M lldb/test/API/lang/objcxx/objc-builtin-types/TestObjCBuiltinTypes.py
    M lldb/test/API/linux/aarch64/tagged_memory_access/TestAArch64LinuxTaggedMemoryAccess.py
    M lldb/test/API/linux/aarch64/unwind_signal/TestUnwindSignal.py
    M lldb/test/API/lua_api/TestLuaAPI.py
    M lldb/test/API/macosx/function-starts/TestFunctionStarts.py
    M lldb/test/API/macosx/objc_exception_recognizer/TestObjCRecognizer.py
    M lldb/test/API/macosx/profile_vrs_detach/TestDetachVrsProfile.py
    M lldb/test/API/macosx/queues/TestQueues.py
    M lldb/test/API/macosx/universal/TestUniversal.py
    M lldb/test/API/python_api/event/TestEvents.py
    M lldb/test/API/python_api/file_handle/TestFileHandle.py
    M lldb/test/API/python_api/findvalue_duplist/TestSBFrameFindValue.py
    M lldb/test/API/python_api/format/TestFormat.py
    M lldb/test/API/python_api/formatters/TestFormattersSBAPI.py
    M lldb/test/API/python_api/frame/get-variables/TestGetVariables.py
    M lldb/test/API/python_api/module_section/TestModuleAndSection.py
    M lldb/test/API/python_api/process/TestProcessAPI.py
    M lldb/test/API/python_api/process/io/TestProcessIO.py
    M lldb/test/API/python_api/sbdata/TestSBData.py
    M lldb/test/API/python_api/sbmodule/TestSBModule.py
    M lldb/test/API/python_api/target/TestTargetAPI.py
    M lldb/test/API/python_api/type/TestTypeList.py
    M lldb/test/API/python_api/value/change_values/TestChangeValueAPI.py
    M lldb/test/API/python_api/value/change_values/libcxx/atomic/TestChangeValue.py
    M lldb/test/API/python_api/value/change_values/libcxx/map/TestChangeMapValue.py
    M lldb/test/API/python_api/watchpoint/TestWatchpointIter.py
    M lldb/test/API/source-manager/TestSourceManager.py
    M lldb/test/API/tools/lldb-dap/coreFile/TestDAP_coreFile.py
    M lldb/test/API/tools/lldb-dap/disassemble/TestDAP_disassemble.py
    M lldb/test/API/tools/lldb-dap/runInTerminal/TestDAP_runInTerminal.py
    M lldb/test/API/tools/lldb-dap/stackTrace/TestDAP_stackTrace.py
    M lldb/test/API/tools/lldb-dap/terminated-event/TestDAP_terminatedEvent.py
    M lldb/test/API/tools/lldb-dap/variables/TestDAP_variables.py
    M lldb/test/API/tools/lldb-server/TestGdbRemoteAttach.py
    M lldb/test/API/tools/lldb-server/TestGdbRemoteAuxvSupport.py
    M lldb/test/API/tools/lldb-server/TestGdbRemoteExpeditedRegisters.py
    M lldb/test/API/tools/lldb-server/TestGdbRemoteRegisterState.py
    M lldb/test/API/tools/lldb-server/TestLldbGdbServer.py
    M lldb/test/API/tools/lldb-server/attach-wait/TestGdbRemoteAttachWait.py
    M lldb/test/API/tools/lldb-server/registers-target-xml-reading/TestGdbRemoteTargetXmlPacket.py

  Log Message:
  -----------
  [lldb][test] Modernize asserts (#82503)

This uses [teyit](https://pypi.org/project/teyit/) to modernize asserts,
as recommended by the [unittest release
notes](https://docs.python.org/3.12/whatsnew/3.12.html#id3).

For example, `assertTrue(a == b)` is replaced with `assertEqual(a, b)`.
This produces better error messages, e.g. `error: unexpectedly found 1
and 2 to be different` instead of `error: False`.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list