astropy / astropy/pytest-arraydiff

pytest-arraydiff giving problems when running pytests coverage module

Đang mở
#20 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
bug
Ngôn ngữ chính
Python
Star
27
Fork
21
Merge trung bình
6 giờ 39 phút
Pull request đã merge (30 ngày)
1

Mô tả

I am using the `pytest-arraydiff` package to test some functions which return arrays. For the tests in question I am using the following decorator:

`@pytest.mark.array_compare(file_format='text')`

I have used the following command to generate test files:

`pytest --arraydiff-generate-path=test_data`

Which generated some test files for me such that when I run:

`pytest --arraydiff`

My test suite runs successfully. Unfortunately I also need to run a coverage check, but running the following command:

`pytest --cov-report html test_file_name.py::test_name --cov=. --arraydiff`

Results in an error:

> FAILED test_cliff_erosion_equations.py::test_main - Exception: File
> not found for comparison test

Is `pytest-arraydiff` not compatible with `pytest`'s coverage module? If not, how else can I test out functions which return arrays? what is the common practice here?

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.