MDL-40541 need to be able to select random q

in unit tests