view tests/failfilemerge.py @ 48478:3444e0b39c30

pytype: stop excluding cmdutil.py Whatever was broken here seems to have been previously fixed. Differential Revision: https://phab.mercurial-scm.org/D11917
author Matt Harbison <matt_harbison@yahoo.com>
date Mon, 13 Dec 2021 00:25:38 -0500
parents f45a4a47f6a8
children 6000f5b25c9b
line wrap: on
line source

# extension to emulate interrupting filemerge._filemerge

from __future__ import absolute_import

from mercurial import (
    error,
    extensions,
    filemerge,
)


def failfilemerge(*args, **kwargs):
    raise error.Abort(b"^C")


def extsetup(ui):
    extensions.wrapfunction(filemerge, 'filemerge', failfilemerge)