The lead changed hands four times before the Wolves clinched victory at the Totally Wicked Stadium to reach their fourth Grand Final in seven years.
Warrington will now have a chance to lift the Super League trophy for the first time in coach Steve Price’s maiden season in charge when they take on Wigan or Castleford at Old Trafford next Saturday.
It brought an abrupt end to the season for St Helens, who led from start to finish in the regular campaign and, after beating the Wolves three times, finished 15 points in front of them in the final table. Previous results counted for little, however, and Warrington will be thankful they opted to fight former Hull winger Lineham’s initial three-match ban imposed for a high tackle against Wigan.
Had the suspension not been reduced, the former Hull winger would not have had the opportunity to punish the Saints defence with two superbly-taken second-half tries that decided a dramatic affair.
Yet there was little sign of the drama after early handling errors inside Saints’ own half from returning England international Jonny Lomax and Mark Percival set the tone for a scrappy opening 40 minutes.
Tyrone Roberts gave his side the lead with an 11th-minute penalty, which was quickly cancelled out by Saints half-back Danny Richardson, with referee Robert Hicks awarding six penalties inside the first 15 minutes.
In a tight first half, the only other score before half-time was a drop goal from Richardson, who found the target a minute after Stefan Ratchford failed with an effort at the other end for Wolves.
Saints scored first after the break, as Richardson’s clever kick over the defence, prop Luke Douglas was able to get a hand to the loose ball for the opening try.
Richardson’s conversion opened up a two-score lead but the Wolves struck back immediately with second rower Jack Hughes demonstrating nice footwork on a diagonal run to the corner. Roberts could not add the goal and Richardson made it 11-6 with a penalty after Hughes had impeded Lomax as he chased his own kick.
Instead of running away with the game, though, Saints were rocked back in the 58th minute when Lineham took a pass from Bryson Goodwin and slid over at the corner for his first try.
That brought the visitors to within a point and Roberts nudged his side back in front with a touchline conversion.
As the tension heightened, Richardson missed a penalty from wide out before he kicked two drop goals, with the second bouncing up off the crossbar.
Still Warrington were not finished, however, and Lineham produced another devastating finish to a flowing crossfield move for his second try and Roberts kicked his third goal to wrap up the scoring.