Add test of detect, detectSeries and detectLimit