Fix bug in tests causing runtime error {badmatch, []}