Skip to content

Consider an iris.testing module #6210

@trexfeathers

Description

@trexfeathers

📰 Custom Issue

Analogous to numpy.testing - a module where we can share our testing conveniences publicly.

We are in the process of implementing iris.tests._shared_utils. Here it is on its feature branch:

"""Provides testing capabilities and customisations specific to Iris."""

iris.tests._shared_utils contains the conveniences that originally belonged to the iris.tests.IrisTest class, which is going to be deprecated once we complete our move to PyTest. I think ideally this could become the iris.testing module.

Motivating factors

  1. The documentation we are writing in Added a style guide for iris pytest #5785 makes many references to this module, which of course isn't documented since it's within iris.tests and is private. It would be more helpful if in a public module, which would mean the references have something to link to.

  2. We know that we have users who use the conveniences in IrisTest / _shared_utils and find them very valuable. This is currently a rather loose contract since they are in private areas of the codebase. I think it would be good to make the conveniences explicitly open to use, although that may only be appropriate once we have finished the PyTest migration and learned all our lessons. If we're not comfortable with fully maintaining stable API we could perhaps incorporate some sort of warning that the code is subject to change?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions