Testard, who joined UB in 1999 as md of its French business, took charge of its Northern European operation in 2001 and then became md of its UK arm in 2004. He will take up his new role on February 21.
David Fish, who has been executive chairman since December 2006, will become non-executive chairman, but will continue to work closely with Testard, said a spokesman.
It has "not been decided yet" who will replace Testard as UK md, he added.
Up for sale
UB, which was acquired by private equity firms Blackstone and PAI Partners in 2006 for £1.6bn, is up for sale. It has been linked to a variety of suitors in recent months, including Shanghai-based Bright Food Group and US giant Campbell Soup Company.
The firm, which owns brands including McVitie’s, Twiglets, Hula Hoops and KP Nuts, posted profits up 14% to £223m on sales of £1.3bn last year, although it has £1.2bn of debt.
UB operates 11 factories in the UK and four factories in Continental Europe. It also has a group technical centre in High Wycombe and a HQ in Hayes, Middlesex.