Detect winning position, and test