Fix test broken by switch to Optional return type