add unit test and  add ability to remove temp export dirs