Comply with PEP8
Improve pyres_command test by using a mock