Return pid when daemon is running
Add more test