The theme of "The Way Up to Heaven" is essentially revenge. Mr. Foster has been secretly tormenting his wife for years with his procrastination and deliberate delays. She doesn't resent his behavior because she can't be sure whether he is doing it intentionally or it is just an annoying character trait. One morning, she find definite evidence that he is a sadist who enjoys torturing her because he knows how important it is to her to be on time for appointments.
Since Mr. Foster uses passive aggression to torment his wife, it is poetic justice that she should get revenge through the same passive aggression. She doesn't actively do anything to kill her husband; she only refrains from doing something. When Mr. Foster delays their trip to the airport by pretending he left something behind in their house, Mrs. Foster, waiting in the car, hears a sound of the elevator getting stuck between the floors. Instead of helping him, she proceeds to the airport, thereby letting him die.
Mrs. Foster's deadly revenge might be considered excessive, but Roald Dahl takes pains to show that Mr. Foster has been using his sadistic passive aggression against his poor, long-suffering wife systematically. Her revenge is a reaction to a whole series of injuries she has suffered at the hands of this petty tyrant over many years.