Unit tests py.test integration

It will be handy on integration tests too.