Started writing tests for detectors.js (#95)