Use environment script for purify_test

This should make it possible to run test when sopt is compiled as an external project.
Uses the Environment script facility of UCL/GreatCMakeCookOff/bd38520a4ccd430bceb189f4312568dd165b1bbe.
Merge branch 'features/with_sopt' of github.com:UCL/purify into features/with_sopt