Suppress plots in the tests

This PR suppress the generated plots on the terminal which was added by @smichr to test issue #7140.