improve check for report file parameter
add test cases and implementation of some