The U.S. has told the British government that it would not repeat accusations that it had helped former U.S. President Barack Obama to spy on President Donald Trump when he was running for the White House.