Actually, I should've split my two statements. From what I've seen and been told, it's better to be undersized in tube cross-sectional width/diameter and it's ok to be slightly undersized in wheel diameter i.e. 700 would work in 27 or 650b would work in 700.
I've heard of people using 26er tubes on 29er bikes. I have attempted this with no success. In the same sitting I tried to use a 32mm 700c tube in a 29er tire. My room mate might have pinched the tube, or it simply exploded. Either way, it didn't work.