President Obama struck just the right balance last week when he addressed the highly contentious issue of student testing. He urged state and local officials to do away with the many meaningless, make-work tests they give each year, while preserving essential, high-quality exams that allow them to tell whether students are making progress and, importantly, whether minority children are being fairly educated.

The president’s comments come at a time when school districts across the nation have angered parents by deluging children with trash exams that serve only to heighten classroom anxiety and eat up precious instructional time.

Congress made a reasonable decision a decade ago when it required the states to give annual math and reading tests in grades three through eight, and once in high school, in exchange for federal education aid. Schools that failed to meet performance targets for two years were labeled as needing improvement and subjected to sanctions.

But Congress could not have anticipated the reaction — more precisely, the overreaction — among school officials who, afraid of being tagged as low-performing, rolled out wave after wave of “diagnostic” exams that were actually practice rounds for the real thing. Worse still, districts often deployed primitive, fill-in-the-bubble exams that gave no sense at all of whether or not children were developing the writing and reasoning skills essential for jobs in the new economy. These junk exams are sometimes still used even after the curriculum they were based on has been abandoned.