Hartley and Gasly set to complete 2017 F1 season with Toro Rosso