We probe the transition between superfluid and Bose glass phases using quantum quenches of disorder in an ultracold atomic lattice gas that realizes the disordered Bose-Hubbard model. Measurements of excitations generated by the quench exhibit threshold behavior in the disorder strength indicative of a phase transition. Ab-initio quantum Monte Carlo simulations confirm that the appearance of excitations coincides with the equilibrium superfluid--Bose-glass phase boundary at different lattice potential depths. By varying the quench time, we demonstrate the disappearance of an adiabatic timescale compared with microscopic parameters in the BG regime.