def METHOD_NAME(self, send_installed_metric_mock):
    with patch("samcli.cli.global_config.GlobalConfig.telemetry_enabled", new_callable=PropertyMock) as mock_flag:
        mock_flag.return_value = True
        runner = CliRunner()
        runner.invoke(cli, ["local", "generate-event", "s3"])
        mock_flag.assert_called_once_with()
        # If prompt is skipped, this should be NOT called
        send_installed_metric_mock.assert_not_called()