def check_mypy_run(<EOL>cmd_line: List[str],<EOL>expected_out: str,<EOL>expected_err: str = "<STR_LIT>",<EOL>expected_returncode: int = <NUM_LIT:1>,<EOL>) -> None:
out, err, returncode = mypy.api.run(cmd_line)<EOL>assert out == expected_out, err<EOL>assert err == expected_err, out<EOL>assert returncode == expected_returncode, returncode<EOL>
Helper to run mypy and check the output.