automatism is a credible and defensible action in the Canadian criminal system (and I see in the American system as well)
One man managed to sleepwalk into his car, drive to his parents in law's house - kill them with a knife - then drive to a police station and turn himself in. All while sleepwalking.
Since there's no way he could have forseen or prevented these acts from occurring while in a non-conscious state, the man was aquittted. Automatism isn't easy to establish as it requires a history of sleepwalking, plus evidence that it was occurring at the time through eyewitness testimony.
Sexosomnia is a bit of a misnomer, I doubt they'd say "killsomnia" or "sexosomnia" during a regular trial.