Make some of the tests poll rather than sleep

The tests should now be faster, however you might want to check they don't flash.