Implications of the impact of prevalence on test thresholds and outcomes: lessons from tuberculosis