Hmm, I've found something interesting that I can't find anything about on Veekun/Research thread.
During a battle I was watching earlier, a pokemon under the effect of Nightmare woke up, and used Rest. Nightmare continued to take effect after this occurred.
I'm not sure whether this is meant to happen or not due to the lack of information on the sources available.
The battle I was watching can be found here, for reference:
http://www.pokemonshowdown.com/replay/hackmons11381489