The Scots actor posted new behind the scenes footage showing the pair fooling around on set.
Vicky, who plays DI Kate Fleming on the programme, is seen trying to give Martin a fright on two occasions, but the Greenock -born star was clearly having none of it
Compston, who stars as DI Steve Arnott, gave the prank a go himself with a little more success – much to the displeasure of his clearly rattled acting colleague.
Martin shared the video on Twitter, while hinting at more twists in store for Line of Duty fans when the next episode of the sixth series airs this Sunday night.
Writing on the social media website, the 36-year-old said: “Big shout out to the media for not giving away any spoilers, much appreciated!
“Especially when they know there will be more than a few @Vicky_McClure like reactions from below to what’s coming in Episode 5.”
A cliffhanger left Line of Duty viewers on the edge of their seat after last weekend’s episode – which many have regarded as one of the best ever made.
Fans’ desperate for answers have spent the past few days coming up with their own theories in anticipation of the next instalment.
Series six has been well-received so far from viewers, with more than 13 million people tuning into the BBC crime thriller last Sunday.
It is not the first time that Martin has hinted at more drama to come in the series. Writing on Instagram earlier this week, he said: “Episode five kicks off as stores reopen and there’s a sale on waistcoats.
“In all seriousness though, if you thought ep 4 ended on a cliffhanger, you’ll need therapy by the end of ep 5.”
Don’t miss the latest news from around Scotland and beyond – Sign up to our daily newsletter here.