Improve test for detectors