Jem's actions on the night on which Dill appears under Scout's bed after running away from home shows both a growing maturity and the ability to recognize right from wrong. By breaking "the remaining code of our childhood"--squealing to Atticus about Dill's whereabouts and separating himself from the other two children--Jem makes it clear that he trusts Atticus to do the right thing. Jem knows that Atticus won't overreact (as, of course, Miss Rachel does), and that he will know what's best for Dill. "I had to tell him," Jem explains.
"You can't run three hundred miles off without your mother knowin'." (Chapter 14)
Scout looks at Jem's betrayal as "the traitor he was," and she is not immediately happy that her brother has decided to rat Dill out and side with the adult view of things. But she eventually recognizes, after Dill eats his fill of food, that "things appeared to have worked out pretty well," so she and Dill "decided to be civil to Jem."