How do I execute code after pytest generates a report (using pytest)?

Viewed 462

So I'm trying to automatically SFTP an html report (that pytest creates) to a server after pytest finishes execution. Does this exist in pytest or do I have to create a wrapper?

I know there are "setup" and "teardown" methods and there exists a teardown method that you can execute after all the tests have ran, but this occurs BEFORE the report is generated (not what I want!).

1 Answers
Related