Browse code

eliminate TEST_ONLY differentiation

devstack is a development and test environment, but by default we were
only installing the runtime dependencies. We should install all the
testing required packages as well.

Change-Id: I7c95927b9daad15766aac9d1276b10ca62efb24c

Sean Dague authored on 2015/03/26 00:55:32
Showing 16 changed files
... ...
@@ -6,7 +6,7 @@ psmisc
6 6
 gcc
7 7
 g++
8 8
 git
9
-graphviz # testonly - docs
9
+graphviz # needed for docs
10 10
 lsof # useful when debugging
11 11
 openssh-server
12 12
 openssl
... ...
@@ -1,6 +1,6 @@
1
-libmysqlclient-dev  # testonly
2
-libpq-dev           # testonly
3
-libssl-dev          # testonly
1
+libmysqlclient-dev
2
+libpq-dev
3
+libssl-dev
4 4
 libxml2-dev
5
-libxslt1-dev        # testonly
6
-zlib1g-dev           # testonly
5
+libxslt1-dev
6
+zlib1g-dev
... ...
@@ -1,12 +1,12 @@
1
-acl     # testonly
1
+acl
2 2
 ebtables
3 3
 iptables
4 4
 iputils-ping
5 5
 iputils-arping
6
-libmysqlclient-dev  # testonly
6
+libmysqlclient-dev
7 7
 mysql-server #NOPRIME
8 8
 sudo
9
-postgresql-server-dev-all       # testonly
9
+postgresql-server-dev-all
10 10
 python-mysqldb
11 11
 python-mysql.connector
12 12
 python-qpid # NOPRIME
... ...
@@ -4,7 +4,7 @@ conntrack
4 4
 kpartx
5 5
 parted
6 6
 iputils-arping
7
-libmysqlclient-dev  # testonly
7
+libmysqlclient-dev
8 8
 mysql-server # NOPRIME
9 9
 python-mysqldb
10 10
 python-mysql.connector
... ...
@@ -1 +1 @@
1
-libxslt1-dev   # testonly
1
+libxslt1-dev
... ...
@@ -6,7 +6,7 @@ euca2ools
6 6
 gcc
7 7
 gcc-c++
8 8
 git-core
9
-graphviz # testonly - docs
9
+graphviz # docs
10 10
 iputils
11 11
 libopenssl-devel # to rebuild pyOpenSSL if needed
12 12
 lsof # useful when debugging
... ...
@@ -1,11 +1,11 @@
1
-acl     # testonly
1
+acl
2 2
 dnsmasq
3 3
 dnsmasq-utils # dist:opensuse-12.3,opensuse-13.1
4 4
 ebtables
5 5
 iptables
6 6
 iputils
7 7
 mariadb # NOPRIME
8
-postgresql-devel        # testonly
8
+postgresql-devel
9 9
 python-eventlet
10 10
 python-greenlet
11 11
 python-iso8601
... ...
@@ -1 +1 @@
1
-libxslt1-dev   # testonly
1
+libxslt1-dev
... ...
@@ -5,7 +5,7 @@ euca2ools # only for testing client
5 5
 gcc
6 6
 gcc-c++
7 7
 git-core
8
-graphviz # testonly - docs
8
+graphviz # needed only for docs
9 9
 openssh-server
10 10
 openssl
11 11
 openssl-devel # to rebuild pyOpenSSL if needed
... ...
@@ -1,6 +1,6 @@
1
-libxml2-devel       # testonly
2
-libxslt-devel       # testonly
3
-mysql-devel         # testonly
4
-openssl-devel       # testonly
5
-postgresql-devel    # testonly
6
-zlib-devel          # testonly
1
+libxml2-devel
2
+libxslt-devel
3
+mysql-devel
4
+openssl-devel
5
+postgresql-devel
6
+zlib-devel
... ...
@@ -1,15 +1,15 @@
1 1
 MySQL-python
2
-acl     # testonly
2
+acl
3 3
 dnsmasq # for q-dhcp
4 4
 dnsmasq-utils # for dhcp_release
5 5
 ebtables
6 6
 iptables
7 7
 iputils
8 8
 mysql-connector-python
9
-mysql-devel  # testonly
9
+mysql-devel
10 10
 mysql-server # NOPRIME
11 11
 openvswitch # NOPRIME
12
-postgresql-devel        # testonly
12
+postgresql-devel
13 13
 rabbitmq-server # NOPRIME
14 14
 qpid-cpp-server        # NOPRIME
15 15
 sqlite
... ...
@@ -17,7 +17,7 @@ libxml2-python
17 17
 numpy # needed by websockify for spice console
18 18
 m2crypto
19 19
 mysql-connector-python
20
-mysql-devel  # testonly
20
+mysql-devel
21 21
 mysql-server # NOPRIME
22 22
 parted
23 23
 polkit
... ...
@@ -1 +1 @@
1
-libxslt-devel   # testonly
1
+libxslt-devel
... ...
@@ -883,16 +883,6 @@ function _parse_package_files {
883 883
                 fi
884 884
             fi
885 885
 
886
-            # Look for # testonly in comment
887
-            if [[ $line =~ (.*)#.*testonly.* ]]; then
888
-                package=${BASH_REMATCH[1]}
889
-                # Are we installing test packages? (test for the default value)
890
-                if [[ $INSTALL_TESTONLY_PACKAGES = "False" ]]; then
891
-                    # If not installing test packages the skip this package
892
-                    inst_pkg=0
893
-                fi
894
-            fi
895
-
896 886
             if [[ $inst_pkg = 1 ]]; then
897 887
                 echo $package
898 888
             fi
... ...
@@ -101,18 +101,17 @@ function pip_install {
101 101
         $cmd_pip install \
102 102
         $@
103 103
 
104
-    INSTALL_TESTONLY_PACKAGES=$(trueorfalse False INSTALL_TESTONLY_PACKAGES)
105
-    if [[ "$INSTALL_TESTONLY_PACKAGES" == "True" ]]; then
106
-        local test_req="$@/test-requirements.txt"
107
-        if [[ -e "$test_req" ]]; then
108
-            $sudo_pip \
109
-                http_proxy=${http_proxy:-} \
110
-                https_proxy=${https_proxy:-} \
111
-                no_proxy=${no_proxy:-} \
112
-                PIP_FIND_LINKS=$PIP_FIND_LINKS \
113
-                $cmd_pip install \
114
-                -r $test_req
115
-        fi
104
+    # Also install test requirements
105
+    local test_req="$@/test-requirements.txt"
106
+    if [[ -e "$test_req" ]]; then
107
+        echo "Installing test-requirements for $test_req"
108
+        $sudo_pip \
109
+            http_proxy=${http_proxy:-} \
110
+            https_proxy=${https_proxy:-} \
111
+            no_proxy=${no_proxy:-} \
112
+            PIP_FIND_LINKS=$PIP_FIND_LINKS \
113
+            $cmd_pip install \
114
+            -r $test_req
116 115
     fi
117 116
 }
118 117
 
... ...
@@ -615,9 +615,6 @@ USE_SCREEN=${SCREEN_DEV:-$USE_SCREEN}
615 615
 # Set default screen name
616 616
 SCREEN_NAME=${SCREEN_NAME:-stack}
617 617
 
618
-# Do not install packages tagged with 'testonly' by default
619
-INSTALL_TESTONLY_PACKAGES=${INSTALL_TESTONLY_PACKAGES:-False}
620
-
621 618
 # Undo requirements changes by global requirements
622 619
 UNDO_REQUIREMENTS=${UNDO_REQUIREMENTS:-True}
623 620