astropy / astropy/pytest-arraydiff

pytest-arraydiff giving problems when running pytests coverage module

Aberta
#20 0 comentários 0 reações 0 responsáveis Ver no GitHub
bug
Linguagem predominante
Python
Estrelas
27
Forks
21
Merge médio
6h 39min
PRs com merge (30d)
1

Descrição

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?

Guia de contribuição

Nenhum guia de contribuição indexado para este repositório

Direção de pesquisa

Comece reproduzindo o comando com test_file_name.py::test_name, --cov-report html, --cov=., e --arraydiff. Compare-o com a invocação funcional de pytest --arraydiff e inspecione test_cliff_erosion_equations.py::test_main; concluído significa identificar se a cobertura altera a busca por arquivos de referência e documentar ou corrigir o comportamento.

Escrita pelo modelo de indexação a partir do texto da issue.

Avaliação

Stack de tecnologia
python
Domínio
testing
Tipo de issue
Bug
Dificuldade
4/5
Tempo estimado
3-5 dias
Status de atividade
Estagnada
Clareza
Precisa de esclarecimento
Facilidade para iniciantes
25/100

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.