pytest-repeat icon indicating copy to clipboard operation
pytest-repeat copied to clipboard

feat: add feature to pad iteration number

Open karrukola opened this issue 9 months ago • 1 comments

This change addresses the discussion in issue #87.

karrukola avatar Mar 05 '25 19:03 karrukola

Submitting logic for review, if OK, e.g. usage of f-strings does not cause problems, I would add the tests:

  • When padding is given and the number of repetions is less than 10, then no padding is applied
  • When padding is set to 0 and the number of repetitions is 10, then the test names are 01, 02...
  • When padding is set to " " and the number of repetitions is 10, then the test names are 1, 2...
  • When padding is set to "" (emtpy string) and the number of repetitions is 10, then no padding is applied
  • When padding is set to two characters, then a warning is emitted and no padding is applied

When running tox, all Python 3.7 jobs fail, it must be the installation on my machine; I get the same results with a clean checkout of main.

karrukola avatar Mar 05 '25 19:03 karrukola