filemerge: when not keeping premerge, don't write markers to context
When premerge is enabled (as it is for non-binary inputs by default)
and the markers are not kept, we currently still write it to the
output context and then restore the previous content right after. With
the refactoring in the previous patch, we can easily avoid that step
and instead write the output in the opposite case (i.e. when it's
successful or when the markers are supposed to be kept).
Differential Revision: https://phab.mercurial-scm.org/D12149
#
# Avoid interference from actual test env:
unset HGTEST_JOBS
unset HGTEST_TIMEOUT
unset HGTEST_PORT
unset HGTEST_SHELL