[PATCH 13/24] qconfig: Move testing into a separate function