God never allows pain without a purpose in the lives of His children. He never allows Satan, nor circumstances, nor any ill-intending person to afflict us unless He uses that affliction for our good. God never wastes pain. He always causes it to work together for our ultimate good, the good of conforming us more to the likeness of His Son (see Romans 8:28-29).
Jerry Bridges (2017). “Transforming Grace”, p.169, NavPress