England were made to wait to wrap up victory in the second Investec Test as Sri Lanka’s batsman put in a much-improved performance in their second innings at Durham.
Having been bowled out for 101 early on day three, Sri Lanka were invited to follow on, trailing by 397 runs, and frustrated England for the most part to close on 309-5.
Angelo Mathews top-scored for the tourists with 80 with opener Kaushal Silva and No 6 Dinesh Chandimal also making half-centuries while James Anderson picked up 2-40 for England.
Sri Lanka require another 88 to make England bat again with the hosts five wickets away from a series win.
The visitors began the day on 91-8 in their first innings and England made short work of mopping up the tail - Stuart Broad had Suranga Lakmal caught behind in the first over of the day before Lahiru Thirimanne skied one to Nick Compton at point, attempting a big shot against Anderson in the fourth.
After skittling Sri Lanka cheaply three times already in the series, England would have hoped for a similar result here as they enforced the follow on. However, there was hitherto unseen resilience shown by the Sri Lankan batsman in their second innings.
Dimuth Karunaratne (26) and Silva looked busy from the off and had patiently put on 38 for the first wicket before Chris Woakes found the former's edge with a ball angled across his body, Joe Root taking the catch at second slip.
Kusal Mendis joined Silva and the pair saw their side through to lunch without any further damage.
Mendis then took 14 runs from the first five balls of an Anderson over shortly after the break but was undone by the last - a brilliant delivery that nipped away off the pitch to take the edge and give Jonny Bairstow a straightforward catch behind the stumps.
Thirimanne, promoted to No 4, was the next man in but he too was dismissed by a beauty, this time from Moeen Ali. The off-spinner turning the ball past the left-hander's edge and knocking back his off stump.
That brought Silva and Mathews together and the pair managed to frustrate England for the next 20 overs. Silva brought up his half-century from 111 balls while, after a steady start, Mathews began to take the attack to the England bowlers.
A stand of 82 was eventually broken by Steven Finn. The Middlesex quick had looked out of sorts for much of the day and it was only when he got riled up that he began to look threatening.
He seemed to gain a yard of pace and that was enough to find a leading edge from Silva (57); Bairstow taking the catch as the ball looped up.
Mathews pushed on and went past 50 in 63 balls after tea, hitting six fours and a maximum in the process but he was eventually dismissed as Anderson returned and induced the edge with Bairstow diving to his right to take the catch.
However, Sri Lanka refused to wilt and Chandimal (54 not out) and Milinda Siriwardana (35 not out) added another 82 to the total to keep England waiting, the former driving beautifully through the covers to bring up his fifty shortly before stumps.
Watch day four of the second Investec Test from 10.30am, Monday, Sky Sports 2. Before then, you can catch highlights of day three (8pm), plus The Verdict (9pm) on Sky Sports 2 on Sunday night.