annotate tests/test-mq-qclone-http @ 7903:490e40816cbd

tests: strip o/s-dependent error messages from some http tests
author John Coomes <john.coomes@sun.com>
date Fri, 27 Feb 2009 17:28:26 -0800
parents 6a49fa7674c1
children 400ffd5f2f14
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
6205
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
1 #! /bin/sh
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
2
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
3 echo "[extensions]" >> $HGRCPATH
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
4 echo "mq=" >> $HGRCPATH
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
5
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
6 mkdir webdir
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
7 cd webdir
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
8
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
9 hg init a
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
10 hg --cwd a qinit -c
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
11 echo a > a/a
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
12 hg --cwd a ci -A -m a
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
13 echo b > a/b
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
14 hg --cwd a addremove
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
15 hg --cwd a qnew -f b.patch
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
16 hg --cwd a qcommit -m b.patch
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
17
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
18 hg --cwd a log --template "{desc}\n"
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
19 hg --cwd a/.hg/patches log --template "{desc}\n"
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
20
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
21 root=`pwd`
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
22
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
23 cd ..
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
24
7525
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
25 echo % test with recursive collection
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
26
6205
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
27 cat > collections.conf <<EOF
7524
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
28 [paths]
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
29 /=$root/**
6205
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
30 EOF
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
31
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
32 hg serve -p $HGPORT -d --pid-file=hg.pid --webdir-conf collections.conf \
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
33 -A access-paths.log -E error-paths-1.log
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
34 cat hg.pid >> $DAEMON_PIDS
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
35
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
36 "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/?style=raw'
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
37
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
38 hg qclone http://localhost:$HGPORT/a b
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
39 hg --cwd b log --template "{desc}\n"
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
40 hg --cwd b qpush -a
b193a6e59131 mq: test for qclone of http repo+queue
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
41 hg --cwd b log --template "{desc}\n"
7524
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
42
7525
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
43 echo % test with normal collection
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
44
7524
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
45 cat > collections1.conf <<EOF
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
46 [paths]
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
47 /=$root/*
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
48 EOF
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
49
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
50 hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf collections1.conf \
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
51 -A access-paths.log -E error-paths-1.log
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
52 cat hg.pid >> $DAEMON_PIDS
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
53
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
54 "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
55
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
56 hg qclone http://localhost:$HGPORT1/a c
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
57 hg --cwd c log --template "{desc}\n"
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
58 hg --cwd c qpush -a
7fc19b12cb6b tests: fix test-mq-qclone-http (broken by e60aaae83323)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 6205
diff changeset
59 hg --cwd c log --template "{desc}\n"
7525
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
60
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
61 echo % test with old-style collection
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
62
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
63 cat > collections2.conf <<EOF
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
64 [collections]
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
65 $root=$root
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
66 EOF
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
67
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
68 hg serve -p $HGPORT2 -d --pid-file=hg.pid --webdir-conf collections2.conf \
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
69 -A access-paths.log -E error-paths-1.log
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
70 cat hg.pid >> $DAEMON_PIDS
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
71
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
72 "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/?style=raw'
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
73
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
74 hg qclone http://localhost:$HGPORT2/a d
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
75 hg --cwd d log --template "{desc}\n"
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
76 hg --cwd d qpush -a
6a49fa7674c1 hgweb: mq repos should be in non-recursive collections, too
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents: 7524
diff changeset
77 hg --cwd d log --template "{desc}\n"