I'm not sure what the outrage is. Mental health courts are used to help seriously disordered people. Here in SF you must have an Axis 1 psychological order to qualify for the program. If you don't no one can send you there.
If you are talking about competency proceedings under PC 1368 that is a different matter. No one should have to stand trial unless they are able to understand the proceedings and assist their lawyer in their defense.