MOT test is definately valid for the full 12 months even if you fail another one in the mean time.
Bear in mind that any car that would fail an MOT is potentially an offence to be driving though (tyre example given is a good one) so if your car has failed an MOT you need to get it fixed before its legal to drive it on the road again, but that was also true before you failed the MOT, you just didnt know it was. But ignorance is no defence of course, so it actually makes no differences if its failed an MOT or not, its still legal if it doesnt have faults, and illegal if it does have faults.