restructured dir and added some tests