South Africa is the only African country to have successfully developed nuclear weapons. It became the first country (followed by Ukraine) with nuclear capability to voluntarily renounce and dismantle its programme and in the process signed the Nuclear Non-Proliferation Treaty in 1991. South Africa undertook a nuclear weapons programme in the 1970s According to former state president FW de Klerk, the decision to build a "nuclear deterrent" was taken "as early as 1974 against a backdrop of a Soviet expansionist threat." South Africa is alleged to have conducted a nuclear test over the Atlantic in 1979, although this is officially denied. Former president de Klerk maintained that South Africa had "never conducted a clandestine nuclear test." Six nuclear devices were completed between 1980 and 1990, but all were dismantled before South Africa signed the Nuclear Non-Proliferation Treaty in 1991. In 2017, South Africa signed the UN treaty on the Prohibition of Nuclear Weapons.