The trial came at a time when Germany is debating tougher security laws after a failed asylum seeker drove a truck into a Christmas market in Berlin on Dec. 19, killing 12 people, in an attack claimed by Islamic State.