Making this work for Mac too

Hi Gianfranco,

I have done some changes to make the tutorial work from mac environment (just place a template for the mktemp), and I have also modified the test script so it can be executed without having to change our current working directory to the one where the test script is located.