The humor found in the nighttime drama of Harper Lee's To Kill a Mockingbird, has to be the issue surrounding Jem's pants.
As with many things we experience in life, some things are humorous only after the event is over. In the novel, when the kids sneak out in their tireless pursuit of knowledge of Boo Radley, they camouflage their presence by crawling through the underbrush in an attempt to sneak closer to the Radley house.
The humor, for me, comes from the classic nature of children on an adventure. There is subterfuge, fear, and common sense in the planning and execution. Their plan is clear; along with their fear is the thrill of the danger of being caught. The reader also witnesses Jem's common sense when he tells the others to spit on the hinges of the gate so that it will move noiselessly.
Harper Lee does an excellent job of transporting the reader to the damp underbrush, to the explosion of discovery (the gunshot), and even the sheer terror the children experience, particularly when Jem falls behind because his pants are caught on the bottom of the fence. He is only able to escape because he kicks them off.
The last piece of humor is the appearance of the children in the midst of the adults who come out to investigate the firing of the gun...as Jem stands there in his boxers. Dill's wonderful imagination steps in to explain the absence of Jem's pants, but fear arrives once again as Jem is told to get the pants back. He knows he cannot leave them on the fence to be discovered in the morning, and so he must return to face his fears all over again. (It is not until the following chapter that the reader learns about the condition in which Jem discovers his pants.)
However, the comedy presented in the form of a childhood prank takes on more serious implications when the gun goes off; it then becomes humorous again when Jem and friends appear without Jem's pants and with an unlikely excuse; but terror returns when Jem must go back for his missing clothing.
In the moment, it may not seem to be funny, but in hindsight, it does provide the reader with a chuckle; and for those who might actually find themselves in a similar situation, humor might be present long after the fact, when the fear is gone and time has softened the sharp edges of the experience.