Fix up functional tests