mapper: added reader as nested class
reader_test: changed to nested class; removed unnecessary imports
removed unnecessary spaces