I've had a similar situation. I was doltish about spatial issues until I spent four years learning landscape architecture, which includes, hah, a lot of design in space - and now pass spatial parts of tests well but not necessarily speedily, as I wasn't a born natural at it though I did catch on. When I took the grading-and-drainage class in school, which involves some math and a lot of space, I cried at least twice trying to figure out the homework, but by the time I was studying for the boards after a couple of years of working in the 'field', it was like taking a test in my hobby, and playing with grading re design became one of my favorite things related to work.
On the failure side, I walked in to university physics class one of two, out of a class of at least a couple of hundred students, who hadn't had high school physics, and I was stone cold lost from day 1, just squeaking out a D because I showed up at the lab hours. I also remember barely living through college algebra, le miserables. I think in those cases, it was a matter of shutting down, a kind of fear closing my brain.