##// END OF EJS Templates
fix traceback in hgweb when URL doesn't end in one of the archive specs...
fix traceback in hgweb when URL doesn't end in one of the archive specs If the last n charecters of the URL doesn't match an entry in archive_specs req.form never has a key 'type'. When achive() looks up 'type' in the form dict it causes a traceback rather than printing an error message.

File last commit:

r5683:396c7010 default
r6669:782dbbdf default
Show More
test-archive-symlinks
32 lines | 567 B | text/plain | TextLexer
/ tests / test-archive-symlinks
Alexis S. L. Carvalho
archive: add symlink support
r4831 #!/bin/sh
Patrick Mezard
Skip test-archive-symlinks if symlinks are not available
r5069 "$TESTDIR/hghave" symlink || exit 80
Alexis S. L. Carvalho
archive: add symlink support
r4831 origdir=`pwd`
hg init repo
cd repo
ln -s nothing dangling
Alexis S. L. Carvalho
run-tests.py: add a default --date "0 0" argument to commit et al...
r5524 # avoid tar warnings about old timestamp
hg ci -d '2000-01-01 00:00:00 +0000' -qAm 'add symlink'
Alexis S. L. Carvalho
archive: add symlink support
r4831
hg archive -t files ../archive
hg archive -t tar -p tar ../archive.tar
hg archive -t zip -p zip ../archive.zip
echo '% files'
cd "$origdir"
cd archive
Thomas Arendsen Hein
Use common readlink.py instead of own implementations per test script.
r5683 $TESTDIR/readlink.py dangling
Alexis S. L. Carvalho
archive: add symlink support
r4831
echo '% tar'
cd "$origdir"
tar xf archive.tar
cd tar
Thomas Arendsen Hein
Use common readlink.py instead of own implementations per test script.
r5683 $TESTDIR/readlink.py dangling
Alexis S. L. Carvalho
archive: add symlink support
r4831
echo '% zip'
cd "$origdir"
unzip archive.zip > /dev/null
cd zip
Thomas Arendsen Hein
Use common readlink.py instead of own implementations per test script.
r5683 $TESTDIR/readlink.py dangling