improved tests with macro for handling and summary