Tester now only runs when it is main

Also fixed warning with sphinx.