improved tests performance by reading mapping file once
changes in tests, refactoring