The insanity defense is the perfect opportunity for a skilled defense attorney to put the idea of diminished capacity into the jurors' minds. Each year, thousands of mentally ill people are arrested in Texas.When someone pleas insanity, they argue they didn't know their behavior was wrong because of a severe mental illness. Texas Penal Code, Sec. 8.01 provides the framework for the defense of insanity in Texas Criminal courts. In most cases, the defense is required to give notice of the intent to plead insanity and mental health problems 21 days before the trial.