pystac icon indicating copy to clipboard operation
pystac copied to clipboard

Use pytest fixtures

Open pjhartzell opened this issue 2 years ago • 2 comments

Since pystac is switching to pytest for testing (#939), we should look at using pytest's fixtures.

pjhartzell avatar Jan 12 '23 15:01 pjhartzell

Just a note that the fixtures currently defined in conftest.py start with test_ which is have pretty non-standard naming. I think something like default_item or simple_item or even just item would be more typical.

jsignell avatar Feb 16 '23 14:02 jsignell

Another note: per https://github.com/stac-utils/pystac/pull/1001#discussion_r1115658197, we should find meaningful names for each test fixture that is created from the test cases. Right now the test cases are numbered 1-8, but if we dig in to each test case, we should be able to come up with a more descriptive name that makes it clear what scenario(s) test case is trying to exercise.

gadomski avatar Feb 23 '23 21:02 gadomski