The problem isn't testing. Testing is fine and is actually necessary. Even testing with socioeconomic bias is okay since you can norm to historic values to see trends.
The problem occurs at two points:
1) when you then use the results of those tests more broadly than applicable.
Comparing results in the same school year on year is generally valid (although you have to watch out for events like a big employer closing). Comparing two different schools close in location requires a bit of finesse. Comparing schools in completely different locations with completely different demographics is generally useless--yet NCLB effectively tries to lump all schools together with the same tests.
2) when you apply those tests to provide punitive measures
Why don't people get that doing this is going distort the system? Software people wail continuously about "you can't judge my craft with objective measures." Practically any measure in software I can dream up: number of bugs fixed, number of bugs found, number of commits, number of lines of code written, etc. will be met with cries of "that doesn't measure my ability" AND "if you promote on those measures, people will start gaming the measures". And they will be right.
Why can't people see that the exact same thing will occur in teaching?
The standard complaint is that only programmers can judge programmers and that non-programmer managers can't judge correctly. Yet, with respect to teaching, we magically think that any moron can judge teaching ability and that non-teaching managers are well equipped to judge teachers.
This is one of my hot buttons. Tech folks are so very quick to defend their own area with "you can't objectively judge and punish me" and so quick to apply "but I can objectively judge and punish you."
And, even when a school is doing things right, it's really hard to keep it going. Positive results take years to show up unequivocally while negative results can appear almost immediately.
See: http://www.thisamericanlife.org/radio-archives/episode/275/t...
The bit about how quickly things dropped one year when they didn't have parents come in 3-times-a-year to review report cards is particularly enlightening. Achievement is getting a lot of little things right, and only the teachers can see when they're right and when they're wrong.
By contrast, it took 10 years to move from 15% passing reading and math to 66%. That's roughly 5% a year, and I suspect the first years were slower than that. 5% is statistical noise to a test--which means that all of the things that were occurring in the first years would have been filtered out by a test. Not the result you wanted.
So, given that achievement at that school is now dropping, what does the test tell us to do? Where does the test say: "Whoops. The teachers are the same, so A) either the children got worse or B) we need to unroll every single change made by administrators in the last year." Where is THAT application of the test?
Now do you see the problem with testing?