okfn-brasil/serenata-toolbox

Could we use Pytest to help address the problems with total testing time for journey tests?

Closed this issue · 4 comments

What is the problem?
Journey tests takes too long to run.
screen shot 2017-08-31 at 19 08 24

How can this be addressed?
I believe that the --durations of Pytest can help us understand what is going on, which test. Like in the image below:
screen shot 2017-08-31 at 19 10 34

Who could help with this issue?
I could address it by myself but I'm open to have someone working on it with me.

Labels
[question]

Want to try it by yourself?
$ pip install pytest
pytest --verbose --duration=10 tests/unit/

This command will run the tests under tests/unit folder show on a terminal report the 10th that takes more time to run.

I'd love to see pytestaround however I still think that the problem of journey is clearcut: we literally download more than 2MM reimbursements from the government serves. This is not what tests are for.

If we mock this downloads with useful subsets of real data ad fixtures, the waiting time is fixed IMHO.

@cuducos I completely agree with you. We need to start somewhere. I see this as very effective way to prioritize which tests attack first and will give us more return over our investment.

What do you think, @cuducos and @jtemporal ?

Nothing against pytest, feel free to go on ; )

Closed by #142