]>
Tony Duckles's Git Repositories (git.nynim.org) - svn2svn.git/blob - tests/t0001-diff-repo.sh
3 test_description
='Test diff-repo.sh
7 PWD
=${TEST_DIRECTORY:-.}
8 PWDURL
=$(echo "file://$PWD" | sed 's/\ /%20/g')
10 REPO2
="$PWD/_repo_tmp2"
11 REPOURL
="$PWDURL/_repo_tmp"
12 REPO2URL
="$PWDURL/_repo_tmp2"
15 rm -rf "$REPO" "$REPO2" "$WC"
18 svnadmin create
"$REPO"
19 svn
mkdir -q -m "Add /trunk" $REPOURL/trunk
20 svn co
-q $REPOURL/trunk
"$WC"
21 mkdir -p "$WC/Module/ProjectA"
22 echo "Module/ProjectA/FileA1.txt (Initial)" >> "$WC/Module/ProjectA/FileA1.txt"
23 echo "Module/ProjectA/FileA2.txt (Initial)" >> "$WC/Module/ProjectA/FileA2.txt"
24 svn
-q add
"$WC/Module"
25 svn ci
-q -m "Initial population" "$WC"
28 "diff-repo: REPO1/trunk == REPO1/trunk" \
29 "./diff-repo.sh $REPOURL/trunk $REPOURL/trunk"
32 "diff-repo: REPO1/trunk != REPO1/trunk/Module" \
33 "./diff-repo.sh $REPOURL/trunk $REPOURL/trunk/Module"
35 rsync
-aq $PWD/_repo_tmp
/ $PWD/_repo_tmp2
38 "diff-repo: REPO1/trunk == REPO2/trunk (identical)" \
39 "./diff-repo.sh $REPOURL/trunk $REPO2URL/trunk"
42 svn co
-q $REPO2URL/trunk
"$WC"
43 echo "Module/ProjectA/FileA1.txt (Edit)" >> "$WC/Module/ProjectA/FileA1.txt"
44 echo "Module/ProjectA/FileA3.txt (New File)" >> "$WC/Module/ProjectA/FileA3.txt"
45 svn
-q add
"$WC/Module/ProjectA/FileA3.txt"
46 svn ci
-q -m "Second commit" "$WC"
49 "diff-repo: REPO1/trunk != REPO2/trunk (changed)" \
50 "./diff-repo.sh $REPOURL/trunk $REPO2URL/trunk"
52 rm -rf "$REPO" "$REPO2" "$WC"