Martin Guptill made 116 as New Zealand eased to victory over Sri Lanka in the final warm-up match ahead of the Champions Trophy.

The Kiwi opener made the most of one particularly short boundary at Edgbaston to hit 10 fours and five sixes in his 76-ball knock.

He retired with the Black Caps well on their way to chasing down Sri Lanka's 356-8, a task they duly completed for the loss of just four wickets - two of them retirements - with captain Kane Williamson adding 88 from 60 balls before he too withdrew to allow others time at the crease before the tournament gets underway on Thursday.

It was a day to forget for the bowlers as batsmen on both sides took full advantage of the short boundaries. Sri Lankan opener Upul Tharanga top-scored in the first innings with 110 from 104 balls while there were also half-centuries for Kusal Mendis (57) and Dinesh Chandimal (55).

Tim Southee's 2-48 from his eight overs was as good as it got for the New Zealand bowlers with Trent Boult (2-47) going at more than nine an over despite two late wickets.

It was a similar struggle for the Sri Lanka bowlers as Guptill and Tom Latham (44) began the reply. Even the wicket of Latham brought little respite as Williamson came in and ensured the onslaught continued.

After Guptill and Williamson had taken their leave, it was left to Corey Anderson to finish the job and he did so in a hurry; the left-hander's six to seal the win, with 23 balls remaining, bringing up his fifty from just 36 deliveries.