Fixed system ENV.cxx, added working test block