France secured their place in the World Cup quarter-finals with a 23-21 victory over Tonga at the Kumamoto Stadium.
France will now face a shootout with England next Saturday to determine who will finish top of Pool C.
Virimi Vakatawa and Alivereti Raka went over for tries for France, with Romain Ntamack booting 13 points. Sonatane Takulua, Malietoa Hingano and Zane Kapeli scored the Tonga tries.
Ntamack kicked France into an early lead after Tonga were penalised for offside.
And two minutes later they went over for the opening try when they turned the ball over in their own half before advancing forward and working it wide to Raka, who sent centre Vakatawa in for the score.
Ntamack converted and then missed another shot at goal before France went in for a second try.
Scrum-half Baptiste Serin took a quick tap penalty and fed Raka and he kicked the ball ahead, collected and touched down, with Ntamack converting from out wide to put France 17-0 up.
Tonga got back into the game shortly before the interval with the help of the TMO after Takulua was judged to have grounded the ball amid some fierce French defence.
France thought they had a third try from flanker Charles Ollivon but the crucial pass from Sebastien Vahaamahina was forward.
And Tonga went straight up the other end and got a try of their own through Hingano.
Cooper Vuna's kick ahead bounced kindly into the hands of Hingano, who gathered and powered over the line and Takulua's conversion brought them within three points at 17-14.
Ntamack then booted another two penalties to give France some breathing space heading into the final 20 minutes.
Damian Penaud had a try disallowed by the TMO for France after Maxime Medard knocked on in the build-up.
Tonga got a third try right at the death when referee Nic Berry played a penalty advantage and Latiume Fosita kicked wide for flanker Kapeli to gather and score in the corner.
Fosita added the extras but Tonga could not gather the ball from the kick-off and France held on for the victory.
Follow Ireland v Samoa on Saturday 12 October (kick-off 11.45am) via the live blog on RTÉ.ie/Sport and the News Now App, watch live on RTÉ2 or listen to live match commentary on RTÉ Radio 1.