Tests confirmed a diagnosis of lung cancer for Pope Leo XIV, the Vatican said in a medical update after he underwent surgery.