That's the case with all of the questions you are asked prior to donating. Have you been to certain countries? Have you had sex with men? Have you had sex with prostitutes? Etc.
It's all based on trusting the word of the donor.
Hopefully, they will test donated blood to confirm that it is disease-free. But they probably won't, due to the costs and the time involved with testing.
Back in the 1990’s, I worked with a guy who got very sick. He tested negative for HIV at first. Several weeks later, he was near death and after running more tests , he tested positive. Turns out, he had unprotected sex with a man in Germany a month or two before. But, while he was infected, so close to his exposure, he tested negative.
It's tested.