Gates of fire, a novel about the Spartans and the battle at Thermopylae. The author, Steven Pressfield wrote about how the Spartans trained:
” The hardship of the exercises is intended less to strengthen the back than to toughen the mind. The Spartans say that any army may win while it still has its legs under it; the real test comes when all strength is fled and the men must produce victory on will alone.”
Having the will to fight on and not quit is more of a trait than it is something you can “learn” through conditioning. A warrior never leaves a fallen comrade behind and only needs to look to his left and right to find a reason not to quit and to keep the will to drive on until the war is won.
Once you learn to subdue you fear and vanquish panic, you will be on your way to achieving the warrior mindset.