You can stop students from printing a test through the browser (and from copying material into the system’s clipboard) by adding a special code to the Instructions area of the Test Information page.

There is NO WAY TO PREVENT ALL PATHS TO PRINT AN ONLINE TEST. Inserting the script posted here prevents printing through the browser, but it is impossible to prevent anyone from using a camera to photograph whatever is displayed on a computer monitor, unless you try to prevent photography by employing human proctors and also require students to have no eyeglasses or pens or watches or other devices that might conceal cameras. (And you must use some other way to prevent use of screen capture software.)