set environment only once
[golang] always set GOPATH and use helper
fixed test for temporary-filename method

Verify file with retrieved name does not exist (the temporary-filename should
not return the path to an existing file). This file must be removed afterwards,
if it was created during the action.