Explicitly delete 'test' template to ensure clean slate

-Also close curl connection explicitly