extracted regular expression datatype to Regexp structure
only run tests if build is ok; delete heap image after running tests