Boards are hard for a reason. It means a lot of people fail, even if they know their shit.
Ask her to imagine that she has three unsuccessful surgeries. It happens, people die, and sometimes you fail as a doctor. Would she give up? Failure doesn't make her a bad doctor, but giving up does.
It sucks right now. She feels terrible, and those feelings are valid. But her value as a doctor, as a person, is not a score on some test. That's just the gate she needs to open, and it's going to take more time and effort.
Take time to mourn this loss, and when she's ready to start studying again, back her up 100%. Believe that she will pass, because there's a patient out there who needs her brain and her hands to live. When they write her biography, this will be a character-building tidbit that demonstrates her resilience.
Also keep in mind, she may well want to give up. There's no shame in moving on with your life if she doesn't want to be a doctor anymore. Let her know that you love her for who she is, not for the letters after her name. You'll be there no matter what, whether she takes the exams 10 more times or if she decides to never take them again. Both paths are hard, and you're along for either. Find out where she wants to end up, and the path ahead becomes obvious.
Source: I am a med school dropout.