How to properly test async Python code with pytest?