[BUG] get_sdist_metadata return value in tests can change
See original GitHub issue(py38) denolf@lindenolf:~/dev/grayskull$ pip list | grep souschef
conda-souschef 2.2.1
(py38) denolf@lindenolf:~/dev/grayskull$ pip list | grep gray
grayskull 1.5.1.dev3+g62509c4.d20220728 (current main branch)
This test passes when I run it like this
pytest tests/test_pypi.py::test_compose_test_section_with_console_scripts
but fails when I do this
pytest tests/test_pypi.py
Somehow get_sdist_metadata
returns something different in both cases. Not sure why.
Issue Analytics
- State:
- Created a year ago
- Comments:9 (9 by maintainers)
Top Results From Across the Web
how to change jest mock function return value in each test?
You can mock the module so it returns spies and import it into your test: import {navigationEnabled, guidanceEnabled} from '../../.
Read more >unittest.mock — mock object library
It allows you to replace parts of your system under test with mock ... You can also specify return values and set needed...
Read more >Catch more bugs: How to produce unit tests in real time
Using a little regular expression magic, you can extract class names, methods, parameters, and return values, and then modify the code in-place, ...
Read more >Best practices for writing unit tests - .NET
Repeatable: Running a unit test should be consistent with its results, that is, it always returns the same result if you don't change...
Read more >Managing return values with PHPUnit mock objects
How to use PHPUnit mock objects to create a virtual laboratory for testing components. Set up stub objects to return values via simple ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
but it can be improved, indeed, putting something like
before the
BaseException
to cover this caseIt cannot be killed by KeyboardInterrupt, but sigkill works as normal