Mercurial > hgsubversion
annotate tests/fixtures/rename-closed-branch-dir.sh @ 1452:4217a050a088
tests: drop hard-coded list of tests
The list of out of date, missing 'test_helpers' and
'comprehensive/test_custom_layout'. Instead, use the discover
functionality introduced in Python 2.7, and available for Python 2.6
and earlier from the 'unittest2' backport.
Tested by invoking 'run.py' both with and without '-A' in Python 2.6 &
2.7, and ensuring that passing comprehensive tests as arguments
continues to work.
As a minor (but welcome) side-effect, this should restore the ability to
test hgsubversion under demandimport; previously, test_util was
imported before we enabled demandimport, so it didn't affect most of
Mercurial. Since unittest2 (and unittest) do define SkipTest, we can
remove the earlier import, restoring the likely originally intended
testing mode.
author | Dan Villiom Podlaski Christiansen <danchr@gmail.com> |
---|---|
date | Sun, 12 Jun 2016 14:55:57 +0200 |
parents | b072dc02d1e3 |
children |
rev | line source |
---|---|
1373
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
1 #!/bin/sh |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
2 # |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
3 # Generate rename-closed-branch-dir.svndump |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
4 # |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
5 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
6 mkdir temp |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
7 cd temp |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
8 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
9 mkdir project |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
10 cd project |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
11 mkdir trunk |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
12 mkdir branches |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
13 mkdir tags |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
14 cd .. |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
15 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
16 svnadmin create testrepo |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
17 CURRENT_DIR=`pwd` |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
18 svnurl=file://"$CURRENT_DIR"/testrepo |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
19 #svn import project-orig $svnurl -m "init project" |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
20 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
21 svn co $svnurl project |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
22 cd project |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
23 svn add * |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
24 svn ci -m "init project" |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
25 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
26 cd trunk |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
27 echo a > a.txt |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
28 svn add a.txt |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
29 svn ci -m "add a.txt in trunk" |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
30 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
31 # Create a branch |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
32 svn up |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
33 cd ../branches |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
34 svn copy ../trunk async-db |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
35 svn ci -m "add branch async-db" |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
36 svn up |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
37 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
38 # Implement feature |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
39 cd async-db |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
40 echo b > b.txt |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
41 svn add b.txt |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
42 svn ci -m "Async functionality" |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
43 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
44 # Merge feature branch |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
45 cd ../../trunk |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
46 svn merge $svnurl/branches/async-db |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
47 svn ci -m "Merged branch async-db" |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
48 cd .. |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
49 svn up |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
50 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
51 # Create branch folder for unnecessary branches |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
52 svn mkdir $svnurl/branches/dead -m "Create branch folder for unnecessary branches" |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
53 svn up |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
54 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
55 # We don't need the 'async-db' branch, anymore. |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
56 svn copy $svnurl/branches/async-db $svnurl/branches/dead -m "We don't need the 'async-db' branch, anymore." |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
57 svn up |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
58 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
59 # Rename 'dead' folder to 'closed' |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
60 svn move $svnurl/branches/dead $svnurl/branches/closed -m "Renamed 'dead' folder to 'closed'" |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
61 svn up |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
62 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
63 # Move 'branches/closed' to 'tags/closed' |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
64 svn move $svnurl/branches/closed $svnurl/tags/closed -m "Moved 'branches/closed' to 'tags/closed'." |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
65 svn up |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
66 |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
67 # Dump repository |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
68 cd .. |
b072dc02d1e3
rename-closed-branch-dir: add a fixture that renames a directory of closed branches
Augie Fackler <raf@durin42.com>
parents:
diff
changeset
|
69 svnadmin dump testrepo > ../rename-closed-branch-dir.svndump |