Where does the law say a judge gets to decide whether one has a good reason or a bad reason to disinherit. Who knows, maybe Jerry Lewis' children were in the right.
Bill Gates held a press conference when his first child was born and announced he was cutting all his children out of his will. Does a judge get to decide that.
Again, this is a state by state issue. Probate laws vary dramatically. But there are definitely court defined “good” and “bad” reasons to leave somebody out of your will. And yes if you cut people out of your will a judge does get to decide that. Of course in many states you can “pre-probate” which really helps, partly because it’s really just you, your lawyer, and the judge. So you get to tell the judge why and the people you’re cutting out aren’t there to say “but”. It’s all terribly complicated, made more complicated because of the quantity of lawyers that tend to show up.