./devel/py-test-relaxed, Relaxed test discovery/organization for pytest

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]


Branch: CURRENT, Version: 2.0.2, Package name: py312-test-relaxed-2.0.2, Maintainer: pkgsrc-users

pytest-relaxed provides 'relaxed' test discovery for pytest.

Has it ever felt strange to you that we put our tests in tests/, then name the
files test_foo.py, name the test classes TestFoo, and finally name the test
methods test_foo_bar? Especially when almost all of the code inside of tests/
is, well, tests?

This pytest plugin takes a page from the rest of Python, where you don't have
to explicitly note public module/class members, but only need to hint as to
which ones are private. By default, all files and objects pytest is told to
scan will be considered tests; to mark something as not-a-test, simply prefix
it with an underscore.


Required to run:
[devel/py-setuptools] [devel/py-decorator] [devel/py-test] [lang/py-six] [lang/python37]

Required to build:
[pkgtools/cwrappers]

Master sites:

Filesize: 27.223 KB

Version history: (Expand)


CVS history: (Expand)


   2024-11-11 08:29:31 by Thomas Klausner | Files touched by this commit (862)
Log message:
py-*: remove unused tool dependency

py-setuptools includes the py-wheel functionality nowadays
   2024-04-03 16:55:20 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-test-relaxed: updated to 2.0.2

2.0.2
- Fix dangling compatibility issues with pytest version 8.x.
   2023-07-18 17:51:28 by Adam Ciarcinski | Files touched by this commit (2) | Package updated
Log message:
py-test-relaxed: updated to 2.0.1

2.0.1
- :bug:`9` Don't try loading Pytest fixture functions as if they were test
  functions. Classifying this as a bug even though it's a moderately sized
  change in behavior; it's vanishingly unlikely anybody was relying on this
  somehow! Thanks to ``@cajopa`` for the report.

2.0.0
- :bug:`- major` Prior to version 2, we failed to correctly support true Pytest
  setup/teardown methods (i.e. ``setup_method`` and ``teardown_method``) and
  these would not get copied to inner class scopes. This has been fixed. We
  still support old nose-style ``setup``/``teardown`` for now, despite them
  going away in Pytest 8.
- :support:`-` Modernize codebase/project a bunch:

  - Dropped support for Python <3.6 (including 2.7)
  - Pytest support upgraded to support, **and require**, Pytest >=7.

    - This plugin never worked on Pytests 5 and 6 anyways, and supporting 5-7
      appears to require a lot more effort than just 7.

  - Behavioral changes in Pytest internals have fixed a handful of sorta-bugs
    present in pytest-relaxed under Pytest versions 3 and 4:

    - The order of nested test display may change slightly, typically for the
      better; eg under older versions, tests defined on a class might have been
      displayed after subclasses/nested tests - now they're more likely to be
      listed first, which was the original intent.
    - These bugs sometimes enabled "state bleed", such as outer scopes
      appearing to grant inner ones attributes set at runtime (eg by the outer
      scope's ``setup``, even when the inner scope redefined ``setup``).

      - If you encounter odd bugs after upgrading, please take a close look at
        your code and make sure you weren't accidentally using such a
        "feature". One good way to test for this is to run the \ 
"newly failing"
        tests by themselves on the old dependencies -- they will likely also
        fail there.
   2022-01-04 21:55:40 by Thomas Klausner | Files touched by this commit (1595)
Log message:
*: bump PKGREVISION for egg.mk users

They now have a tool dependency on py-setuptools instead of a DEPENDS
   2021-10-26 12:20:11 by Nia Alarie | Files touched by this commit (3016)
Log message:
archivers: Replace RMD160 checksums with BLAKE2s checksums

All checksums have been double-checked against existing RMD160 and
SHA512 hashes

Could not be committed due to merge conflict:
devel/py-traitlets/distinfo

The following distfiles were unfetchable (note: some may be only fetched
conditionally):

./devel/pvs/distinfo pvs-3.2-solaris.tgz
./devel/eclipse/distinfo eclipse-sourceBuild-srcIncluded-3.0.1.zip
   2021-10-07 15:44:44 by Nia Alarie | Files touched by this commit (3017)
Log message:
devel: Remove SHA1 hashes for distfiles
   2020-05-16 19:38:40 by Adam Ciarcinski | Files touched by this commit (9)
Log message:
pytest from versioned deps.
   2019-06-17 23:06:29 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-test-relaxed: updated to 1.1.5

1.1.5:
Fix compatibility with pytest versions 3.3 and above.