Move data_dir from constant to ENV for easy testing