annotate tests/test-share @ 10301:56b50194617f

templates: rename `Last change' column in hgwebdir repository list. This patch changes column headers in the templates that previously said `Last change' to `Last modified'. Neither code nor functionality are changed other than that. For some time now, I have been annoyed by the fact the `Last change' column didn't list the age of the youngest changeset in the repository, or at least tip. It just occurred to me that this is because the wording is slightly misleading; what the column in fact lists is when the repository was last *modified*, that is, when changesets was last added or removed from it. The word `change' can be understood as referring to the changeset itself. Using `changed' would be ever so slightly less amigous. However, the standard nomenclature in this case is `modification date' and `Last modified', which is incidentally entirely unambigous. Hence, `Last modified' is the wording used.
author Dan Villiom Podlaski Christiansen <danchr@gmail.com>
date Sun, 24 Jan 2010 20:51:53 +0100
parents 66d8ec33da32
children 2250fc372d34
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
9990
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
1 #!/bin/sh
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
2
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
3 echo "[extensions]" >> $HGRCPATH
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
4 echo "share = " >> $HGRCPATH
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
5
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
6 echo % prepare repo1
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
7 hg init repo1
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
8 cd repo1
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
9 echo a > a
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
10 hg commit -A -m'init'
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
11
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
12 echo % share it
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
13 cd ..
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
14 hg share repo1 repo2
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
15
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
16 echo % contents of repo2/.hg
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
17 cd repo2
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
18 [ -d .hg/store ] \
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
19 && echo "fail: .hg/store should not exist" \
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
20 || echo "pass: .hg/store does not exist"
10082
66d8ec33da32 test-share: Solaris sed can't handle never-ending lines
Mads Kiilerich <mads@kiilerich.com>
parents: 10078
diff changeset
21 # Some sed versions appends newline, some don't, and some just fails
66d8ec33da32 test-share: Solaris sed can't handle never-ending lines
Mads Kiilerich <mads@kiilerich.com>
parents: 10078
diff changeset
22 (cat .hg/sharedpath; echo) | head -n1 | sed "s:$HGTMP:*HGTMP*:"
9990
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
23
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
24 echo % commit in shared clone
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
25 echo a >> a
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
26 hg commit -m'change in shared clone'
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
27
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
28 echo % check original
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
29 cd ../repo1
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
30 hg log
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
31 hg update
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
32 cat a # should be two lines of "a"
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
33
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
34 echo % commit in original
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
35 echo b > b
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
36 hg commit -A -m'another file'
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
37
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
38 echo % check in shared clone
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
39 cd ../repo2
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
40 hg log
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
41 hg update
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
42 cat b # should exist with one "b"
c1d940d31aea share: add a test script.
Greg Ward <greg-hg@gerg.ca>
parents:
diff changeset
43
10078
97c75ad3b1a0 hgweb: Make get_mtime use repository to find store path.
Brendan Cully <brendan@kublai.com>
parents: 10062
diff changeset
44 echo % hg serve shared clone
97c75ad3b1a0 hgweb: Make get_mtime use repository to find store path.
Brendan Cully <brendan@kublai.com>
parents: 10062
diff changeset
45 hg serve -n test -p $HGPORT -d --pid-file=hg.pid
97c75ad3b1a0 hgweb: Make get_mtime use repository to find store path.
Brendan Cully <brendan@kublai.com>
parents: 10062
diff changeset
46 cat hg.pid >> $DAEMON_PIDS
97c75ad3b1a0 hgweb: Make get_mtime use repository to find store path.
Brendan Cully <brendan@kublai.com>
parents: 10062
diff changeset
47
97c75ad3b1a0 hgweb: Make get_mtime use repository to find store path.
Brendan Cully <brendan@kublai.com>
parents: 10062
diff changeset
48 "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/raw-file/'