[Lldb-commits] [PATCH] D86821: [lldb] Make the majority of the lit configuration values optional for the API tests

Jonas Devlieghere via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Aug 28 15:20:45 PDT 2020


JDevlieghere created this revision.
JDevlieghere added reviewers: rupprecht, labath.
Herald added subscribers: danielkiss, teemperor.
JDevlieghere requested review of this revision.

LIT uses a model where the test suite is configurable trough a `lit.site.cfg` file. Most of the time we use the `lit.site.cfg` which has a bunch of default values, generated by CMake, that match the current build configuration. However, nothing prevents you from running the test suite with a different configuration, either by overriding some of these values from the command line, or by passing a different  `lit.site.cfg`.

Many of those configurationvalues are optional but they still need to be set because `lit.cfg.py` is accessing them directly. This patch changes the code to use `getattr` to return the attribute if it exists. This makes it possible to specify a minimal `lit.site.cfg` with only the mandatory/desired configuration values.


Repository:
  rLLDB LLDB

https://reviews.llvm.org/D86821

Files:
  lldb/test/API/lit.cfg.py

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D86821.288713.patch
Type: text/x-patch
Size: 6782 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20200828/0401ae9e/attachment.bin>


More information about the lldb-commits mailing list