[all-commits] [llvm/llvm-project] dddf4c: [lldb/test] Make category-skipping logic "platform...

Pavel Labath via All-commits all-commits at lists.llvm.org
Tue Mar 15 05:42:28 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: dddf4ce034a8e06cc1351492dceece3fa2344c14
      https://github.com/llvm/llvm-project/commit/dddf4ce034a8e06cc1351492dceece3fa2344c14
  Author: Pavel Labath <pavel at labath.sk>
  Date:   2022-03-15 (Tue, 15 Mar 2022)

  Changed paths:
    M lldb/packages/Python/lldbsuite/test/dotest.py
    M lldb/packages/Python/lldbsuite/test/lldbplatformutil.py

  Log Message:
  -----------
  [lldb/test] Make category-skipping logic "platform"-independent

The decision which categories are relevant for a particular test run
happen very early in the test setup process. They use the SBPlatform
object to determine which categories should be skipped. The platform
object created for this purpose transcends individual test runs.

This setup is not compatible with the direction discussed in
<https://discourse.llvm.org/t/multiple-platforms-with-the-same-name/59594>
-- when platform objects are tied to a specific (SB)Debugger, they need
to be created alongside it, which currently happens in the test setUp
method.

This patch is the first step in that direction -- it rewrites the
category skipping logic to avoid depending on a global SBPlatform
object. Fortunately, the skipping logic is fairly simple (and I believe
it outght to stay that way) and mainly consists of comparing the
platform name against some hardcoded lists. This patch bases this
comparison on the platform name instead of the os part of the triple (as
reported by the platform).

Differential Revision: https://reviews.llvm.org/D121605




More information about the All-commits mailing list