Fixed a serious bug in the build system and moved the data directory inside the testapplication directory