Welcome, Mjlee!
It's grammatical but unlikely.
As you've written it, "when Tom faced the unjust situation" is what showed her courage. Facing the unjust situation is more likely to show Tom's courage than someone else's.
Or you might be using "showed" to mean "demonstrated." But again, it's more likely that it would demonstate Tom's courage.
Adding a female name or pronoun — "that Judy showed her courage" or "that she showed her courage" — might be what you're trying to say.
Did you make the sentence up? Did you read it? Did you hear someone say it?
Always tell us the source of your examples.