From Driven to Distraction:

While psychological testing can be very helpful, it is not definitive. Children who have ADD can appear not to have it when psychologically tested. This is because the structure, novelty, and motivation associated with the testing procedure can effectively, for the moment, “treat” the child’s ADD

This echoes my experience. I didn’t get my ADHD diagnosis, despite my mother’s suspicion, until my early 20s.