<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=http://email.email.llvm.org/c/eJylVNtu2zAM_RrnRYihyHEuD37I2g3oMGDA0B_QhY61KZIhyU3z9yOVtOllxTAMCCJLpA4PD0mpYE5dJRp2M8UIPjMFg3ywYYoVv6347vx_51nVfnLWAxPtumpvK7EZch5T1ewq8QV_e5uHSdU6HHDj3MPTMh9j-Ak641a5oHDhRm_aFRjBgfdqtTRmrRWXC25U0-p2oxvoty2s0FU76ffzHIJLc3jMUV7PrDnhhky4xMnPr-f1iKbmGxEVW4ZMZWbZHoCFnh2jzdbv0VCJG1at-PurK86kMYnlAchh7mzKcz2A_pXIFsZsg2c5MOmZ9Q9By_PBgGFsYk5miGxKYMgnQ8rsBT77jrDxApKKB4ZJOtoxE1Wo93WJ-hyQcpARmHQpELEL7oChrtEpGTVl5kN-5q2D7-3-Srl-WVCq-A9IkyM1GMQYXtX7HjEK9RcJjtH6nJCHY-ClckjkTJLN2QGkL0C2pEcUDPQS4VmCzEJEsU7IGV3OtKaI1x-svLJ9I3DN7nq69BTjCKgBCoTlQkU-AnmTMsmCtgRFQRKnJAGmZvdFwFToTImIXWqBlYt0D880lBNqAOqdSuwuZEqtCfIChxZ2kCecHXIytu-hzFIfaRx2f0OhZiE3dSqePvg5iV_UQrlLm7xs-xt2HEiOj9KmvEaZqAV1wKnW2Z3eVf_z44gGdPnjwN9_BJ2GMDm69BThItvbbsFMX1NOZ78LoWc53rQSMb-UaGa6xmybrZzJKQ8hdl8h7cZxNkXX_fPbY1OaIOFH2zQbPhu6LV_JxWK5bNXWrNV60SojG7XWG6nFtuV65qQClzp89iohPBxZgcBvfP1m_8_AdoILwRdiuVjwJef1eqn0agFtu1pDIzaiWnI4SOtqwqlD3M9iVyDVtE9oJAHT1YjFsHsPUAgjw2yzg-7d6_Y0xccYqLuK6LNCrSu8fgPyNgMt>53380</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            run-clang-tidy.py prints wrong checks
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          JesApp
      </td>
    </tr>
</table>

<pre>
    # Current behaviour

In [line 257](https://github.com/llvm/llvm-project/blob/0dc856ed20e0fb64dd7cb0a10db35c58c3ef95e6/clang-tools-extra/clang-tidy/tool/run-clang-tidy.py#L257) (at time of writing), `run-clang-tidy.py` adds the `-list-checks` option to an invocation that is later used to test clang-tidy. Other options to the script (e.g. `-checks`) are also added to this invocation, but not the `-config` option.

# Resulting error

The test invocation prints all enabled checks - meaning either the default set or anything configured via the `-checks` option. If any checks were (un-)configured via the `-config` option, these are not printed. This is confusing to the user, since the list of *checks that are printed* may be *different from* the list of *checks that are used* by the non-testing calls to clang-tidy, where the `-config` option is passed correctly.

# Expected behaviour

The `-config` option should be passed to the test invocation of clang-tidy, so the correct list of enabled checks is printed.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyVVMFu2zAM_Rr7IsRQ5DixDz5k7QZ0GDBg6A_IMh1rUyRDkpPm70cqSdOlK4YBQWSJ1OPjI6nO9ac2EyV7mL0HG1kHozxoN_uMP2Z8e_5_siyrPhltgYlqk1WPmajHGKeQldtMfMHfTsdx7grl9rgx5nBdFpN3P0FF3HbGdbjwXtXVGnrBgQ_detX3G9VxueR9V1aqqlUJQ1PBGl2VkXa3iM6ZsICX6OXtTPcn3JAJFz_bxe28mNBUfiOiomHIVEYW9R6YG9jR66jtDg2ZeGDZmr-_uuZM9n1gcQRyWBgd4kKNoH4FsrkpamdZdExapu3BKXk-GDGMDszICJ7NAXryiRAie4PPviOsv4CE5IFhgvJ6ikQVil2Ror4GpBykByZNcETsgjtiqFt0SqabI7MuvvJWzg56d6NcvC0oVfwHhNmQGgy8d3_U-xkxEvU3CU5e2xiQh2FgZWeQyJkkW7A9SJuAdEqPKPQwSIRnASJzHsU6IWd0OdOaPV4_aHljeydwwZ4GunSNcQTUAAXCcqEiH4HcpUyyoC1AUpDESUlAX7DnJGBIdOZAxC61wMp5uodnCtIJNQD1Tia2FzKp1gR5gUML28sTzg459XoYIM3S4Gkctv9CoWYht-6UPK2zCxI_qYVypzZ52_YP7DiSHB-lTXlNMlALKodTraI5vav-55cJDejy14F__gg6jG42dOka4SLbfbdgpn9SDme_C6FXOe5aiZhfSpT3bdk3ZSPzqKOB9t2kXjvy6B0plQDy2Zv2v18mHcIMAT-qsqx5PraDqFewWXWiGZZKNLxUQ7NZAzRdXdXLXuRGdmBCi49iJoSFI0sQ-I1vY65bwYXgS7FaLvmK8wKR1HoJVbXeQClqka047KU2BfEonN_lvk2UunkX0EjihJsRhdY7C5DCIb6c4-h8-xXCdpryFLlNzH8D-YztnA">