Use proper temp directories for each OS

Also, there was a failing test on Windows ("should shell-escape files").
Since now, it's not.