title: Customizing pytest parameterized test name
body: <p>I've the following tests:</p>
  <pre><code>@pytest.mark.parametrize(
      &quot;nums&quot;,
      [[3, 1, 5, 4, 2], [2, 6, 4, 3, 1, 5], [1, 5, 6, 4, 3, 2]]
  )
  def test_cyclic_sort(nums):
      pass
  
  
  @pytest.mark.parametrize(
      &quot;nums, missing&quot;,
      [([4, 0, 3, 1], 2)]
  )
  def test_find_missing_number(nums, missing):
      pass
  </code></pre>
  <p>I'd like to customize the test names to include the input array. I've read the <a href="https://docs.pytest.org/en/stable/example/parametrize.html#different-options-for-test-ids" rel="nofollow noreferrer">pytest docs</a>, and <a href="https://stackoverflow.com/q/37575690/839733">this question</a> and <a href="https://stackoverflow.com/q/45879028/839733">this question</a>, but none answer the following questions:</p>
  <ol>
  <li>What is passed to the id func? In my code above, the first test takes one parameter, the second takes two.</li>
  <li>pytest docs use a top-level function for id, whereas I'd like to put my tests in a class and use a <code>@staticmethod</code>. Trying to reference the static method with <code>TestClass.static_method</code> from inside <code>TestClass</code> gives an error in PyCharm; what is the correct syntax for doing this?</li>
  </ol>
  <p><strong>Edit:</strong>
  Created <a href="https://github.com/pytest-dev/pytest/issues/8448" rel="nofollow noreferrer">https://github.com/pytest-dev/pytest/issues/8448</a>.</p>