added updated code for test env