The US will not accept a North Korea armed with nuclear weapons, a top US envoy has said, days after Pyongyang announced plans for a nuclear test.