I haven't studied the game mechanics, but there is no such thing as an AI. An AI would not land on the mine, but mechanics telling the troop to hit where it hurts most will.
If a trap is invisible to the AI (as it should be), the move makes perfect sense.