chiark / gitweb /
Test suite: Replace assignments to p with t-select-package
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 10 Jul 2015 23:32:10 +0000 (00:32 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 10 Jul 2015 23:36:16 +0000 (00:36 +0100)
tests/lib
tests/tests/distropatches-reject
tests/tests/drs-push-rejects

index fbe04b7..ebfe5a7 100644 (file)
--- a/tests/lib
+++ b/tests/lib
@@ -128,8 +128,12 @@ t-worktree () {
        t-untar $troot/worktrees/${p}_$1
 }
 
-t-git () {
+t-select-package () {
        p=$1
+}
+
+t-git () {
+       t-select-package $1
        v=$2
        mkdir -p $tmp/git
        local gs=$troot/git-srcs/${p}_$v.git
@@ -155,7 +159,7 @@ t-has-ancestor () {
 }
 
 t-prep-newpackage () {
-       p=$1
+       t-select-package $1
        v=$2
        t-archive-none $p
        t-git-none
@@ -169,7 +173,7 @@ t-prep-newpackage () {
 }
 
 t-archive-none () {
-       p=$1
+       t-select-package $1
        mkdir -p $tmp/aq $tmp/mirror/pool/main
 
        local suite=sid
index c702c37..452fa40 100755 (executable)
@@ -2,8 +2,6 @@
 set -e
 . tests/lib
 
-p=ruby-rails-3.2
-
 t-archive ruby-rails-3.2 3.2.6-1
 t-git-none
 
index 3ce1447..3782890 100755 (executable)
@@ -5,7 +5,7 @@ set -e
 t-drs
 t-git-none
 
-p=pari-extra
+t-select-package pari-extra
 t-worktree drs
 
 cd $p