Stock markets in South Korea and Japan have fallen after announcement North Korea has carried out nuclear testss.