Add option to cancel test after timeout

Default timeout is 5 minutes

https://bugzilla.gnome.org/show_bug.cgi?id=727836