gen_test requires `timeout` passed as a keyword argument
Fix and simplify testing of gen_test