No, I do not believe it is the most important factor in shaping character. I say that because I don't like making blanket statements like that. They eliminate any potential for later evidence to change your mind. I believe that adversity is important in shaping character. But I also believe that how a person is raised is equally important. A person's character is also greatly shaped by the people that surround a person. I do not believe that a single factor can be identified as the most important factor affecting how all people's character is shaped. There are simply too many variables.
With that said, adversity does contribute to John's character in The Crucible. Unfortunately, the adversity that John faces does not always create positive character traits in John. The reader knows that John cheated on Elizabeth with Abigail. The reader finds out that Elizabeth was ill for quite some time, and John broke his marriage vows.
But in my sickness - you see, sir, I were a long time sick after my last baby, and I thought I saw my husband somewhat turning from me.
John is for sure is struggling with honoring his wedding vows, and being stuck in, what he considers, a loveless marriage. He's facing internal adversity, and chooses to do something that causes him great guilt, further marital problems, and a potential fallout from the community of Salem.
As the witchcraft trials continue, and more and more innocent people are taken to be executed, John knows that he can put a stop to it. He knows that in order to do so though, he must destroy his good name. It's a huge challenge for him, but in the end he does it. Unfortunately it doesn't work, and he is still taken to be executed.
Finally, in act 4, John has a chance to confess to a lie and live. It's again a tough choice, because John knows all that he has left is his good name.
Proctor, with a cry of his whole soul: Because it is my name! Because I cannot have another in my life! Because I lie and sign myself to lies! Because I am not worth the dust on the feet of them that hang! How may I live without my name? I have given you my soul; leave me my name!
In the end, John chooses to be a good man, a good Christian, a good friend, etc. and not confess to a lie. He is killed yes, but there is no doubt in Elizabeth's mind and the audience's mind that John's character is now irrefutably good.
Elizabeth, supporting herself against collapse, grips the bars. of the window, and with a cry: He have his goodness now. God forbid I take it from him!