view tests/test-merge-types @ 10092:f1bf64abcb1b stable

doc/Makefile: Fix rst2html detection Displaying the output from the failing call to "which" didn't prevent make from doing stupid things later. We now only search for "rst2html" and fallback to "rst2html.py". If neither name is found, make will eventually abort when we try to use $(RST2HTML).
author Mads Kiilerich <mads@kiilerich.com>
date Wed, 16 Dec 2009 23:59:50 +0100
parents 026eb80060d8
children
line wrap: on
line source

#!/bin/sh

hg init
echo a > a
hg ci -Amadd       # 0

chmod +x a
hg ci -mexecutable # 1

hg up 0
rm a
ln -s symlink a
hg ci -msymlink    # 2
hg merge --debug

echo % symlink is local parent, executable is other

if [ -h a ]; then
    echo a is a symlink
    $TESTDIR/readlink.py a
elif [ -x a ]; then
    echo a is executable
else
    echo "a has no flags (default for conflicts)"
fi

hg update -C 1
hg merge --debug

echo % symlink is other parent, executable is local

if [ -h a ]; then
    echo a is a symlink
    $TESTDIR/readlink.py a
elif [ -x a ]; then
    echo a is executable
else
    echo "a has no flags (default for conflicts)"
fi