Weapons in which the energy is provided by nuclear fission or fusion have only twice in history been detonated outside of a controlled test environment, in the Hiroshima and Nagasaki events in World War II.
Since then, the world has nearly gone to nuclear war as a result of international conflict (during the Cuban Missile Crisis) and by accident. There have also been a number of narrowly-averted accidental nuclear detonations. See this timeline for a sobering look at how close we have come.
This question (which any sane person will hope resolves negatively) regards the probability that a nuclear detonation will occur by Jan 1, 2020, outside of controlled tests. This could include:
Deliberate or nuclear attack.
Accidental nuclear attack (launched by accident or on the basis of erroneous information.)
Accidental detonation of a weapon.
For these purposes we do not consider a radiological weapon — where any fission/fusion energy is energetically sub-dominant to chemical or other explosives — to be a nuclear attack.