fixed lazy require for requireDir

also added tests