@@ -245,8 +245,7 @@ By default, tests with no ``order`` mark are executed after all tests with
245245positive ordinal numbers (or the respective names), and before tests with
246246negative ordinal numbers. The order of these tests in relationship to each
247247other is not changed. This behavior may slightly change if the option
248- :ref: `sparse-ordering ` is used and the ordinals are not contiguous (see
249- below).
248+ :ref: `sparse-ordering ` is used and the ordinals are not contiguous.
250249
251250
252251Order relative to other tests
@@ -341,7 +340,7 @@ The `pytest-dependency <https://pypi.org/project/pytest-dependency/>`__
341340plugin also manages dependencies between tests (skips tests that depend
342341on skipped or failed tests), but currently doesn't do any ordering. If you
343342want to execute the tests in a specific order to each other, you can use
344- ``pytest-ordering ``. If you want to skip or xfail tests dependent on other
343+ ``pytest-order ``. If you want to skip or xfail tests dependent on other
345344tests you can use ``pytest-dependency ``. If you want to have both behaviors
346345combined, you can use both plugins together with the
347346option :ref: `order-dependencies `--see below for more information.
@@ -352,23 +351,6 @@ There are a few command line options that change the behavior of the
352351plugin. As with any pytest option, you can add the options to your
353352``pytest.ini `` if you want to have them applied to all tests automatically.
354353
355- ``--indulgent-ordering ``
356- ------------------------
357- You may sometimes find that you want to suggest an ordering of tests, while
358- allowing it to be overridden for good reason. For example, if you run your test
359- suite in parallel and have a number of tests which are particularly slow, it
360- might be desirable to start those tests running first, in order to optimize
361- your completion time. You can use the ``pytest-order `` plugin to inform pytest
362- of this.
363-
364- Now suppose you also want to prioritize tests which failed during the
365- previous run, by using the ``--failed-first `` option. By default,
366- pytest-order will override the ``--failed-first `` order, but by adding the
367- ``--indulgent-ordering `` option, you can ask pytest to run the sort from
368- pytest-order *before * the sort from ``--failed-first ``, allowing the failed
369- tests to be sorted to the front (note that in pytest versions from 6.0 on,
370- this seems not to be needed anymore, at least in this specific case).
371-
372354.. _order-scope :
373355
374356``--order-scope ``
@@ -389,6 +371,23 @@ separate test functions, these test functions are handled separately from the
389371test classes. If a module has no test classes, the effect is the same as
390372if using ``--order-scope=module ``.
391373
374+ ``--indulgent-ordering ``
375+ ------------------------
376+ You may sometimes find that you want to suggest an ordering of tests, while
377+ allowing it to be overridden for good reason. For example, if you run your test
378+ suite in parallel and have a number of tests which are particularly slow, it
379+ might be desirable to start those tests running first, in order to optimize
380+ your completion time. You can use the ``pytest-order `` plugin to inform pytest
381+ of this.
382+
383+ Now suppose you also want to prioritize tests which failed during the
384+ previous run, by using the ``--failed-first `` option. By default,
385+ pytest-order will override the ``--failed-first `` order, but by adding the
386+ ``--indulgent-ordering `` option, you can ask pytest to run the sort from
387+ pytest-order *before * the sort from ``--failed-first ``, allowing the failed
388+ tests to be sorted to the front (note that in pytest versions from 6.0 on,
389+ this seems not to be needed anymore, at least in this specific case).
390+
392391.. _sparse-ordering :
393392
394393``--sparse-ordering ``
0 commit comments