Montgomery's conversion made it 17-6, and South Africa took an 18-point lead when No. 8 Danie Rossouw crossed the try line in support after Francois Steyn snaffled the ball following an error by fly-half Juan Martin Hernandez just before half-time.
That included a seventh-wicket stand of 82 between Francois du Plessis (54) and home captain Glen Chapple (39) before Martin-Jenkins wrapped up the tail.