12 Commits

Author SHA1 Message Date
whoami-rajat
deadc7c439 Fix : sort variables fetched from env list
In bionic, when exporting env variables, the env list displays
variables in unsorted format.
While fetching we are getting 'https_proxy' before 'http_proxy'
which is failing in comparison to our expected values[1].
This patch sorts the variables fetched from env.

[1] http://logs.openstack.org/30/643130/3/check/devstack-unit-tests/effbf7a/job-output.txt.gz#_2019-03-13_23_12_35_465026

Change-Id: Ie504eabf0d3fec1b97bc711e2702c06bcf75d158
2019-03-14 11:06:15 +05:30
Sean Dague
4da0fa8c13 Always install apache and proxy-uwsgi
We're going to want to start using it by default so just start with
always installing it. This should not negatively impact anything else.

Also had to fix the test using cowsay, now that cowsay depends on
cowsay-off.

Part of uwsgi in devstack.

Change-Id: I8306a992d9d006bc0130a255145a6880065aa0df
2017-04-14 15:41:02 -04:00
Mark Vanderwiel
d99c29032b Add dependency for hexdump
hexdump is used in common function generate_hex_string which is
used by nova and heat.  The current general dependencies do not
have this dependency covered, instead it is usually pulled in by
other implicit dependencies when a full devstack is built. In
cases where only a subset is built (like just Heat and keystone)
hexdump is missing.

Added unit tests for the generate_hex_string function.

Depends-On: Ib47d802a31a0f4c2a49daa7e6698e37c70a2365a
Change-Id: I77c8c2019fb8b8174cdfaed3e56ebf728f0732b7
Closes-Bug: #1558672
2016-03-22 09:34:04 +11:00
Mahito OGURA
54dc19ecad Add export_proxy_variables() tests to test_functions.sh
In test_functions.sh, There aren't export_proxy_variables() tests.
This patch add test of export_proxy_variables to test_funstions.sh.

Change-Id: I76f2bab84f4019961e612b0bff0ab66646b6e160
2015-07-15 23:31:51 +09:00
fumihiko kakuma
8606c98c53 Fix remove_disabled_extensions to remove an extension at the last position
remove_disabled_extensions do matching by '$ext_to_remove","'. So it doesn't
match an extension at the last position in extensions_list.
This patch fixes that.

Closes-Bug: #1443254
Change-Id: I194b483de797697ba06b320cf33f1bac67fc0cc7
2015-05-26 12:38:35 +09:00
Jenkins
641dd9ff23 Merge "Fix negated services with common prefix" 2015-05-07 02:48:20 +00:00
Sean Dague
7efba991f7 don't source openrc
There is actually no reason why we need openrc for these tests, don't
source it as it prevents some ip math errors from randomly killing
tests.

Change-Id: Iface7c21898d92e14e840379938b25844cd85565
2015-04-28 13:15:22 -04:00
Ian Wienand
2796a82ab4 Fix negated services with common prefix
The current sed matching mixes up common-prefix matching;
e.g. "-q-lbaas,q-lbaasv2" is changed into just "v2"

This is more verbose, but I think more reliable.  See also
Ib50f782824f89ae4eb9787f11d42416704babd90.

Change-Id: I3faad0841834e24acc811c05015625cf7f848b19
2015-04-23 15:10:25 +10:00
Ian Wienand
09f4ad2279 Convert test_functions.sh to use unittest helpers
This currently does not exit with any failure code when tests are
failing.  Convert it to use the helper functions from unittest.sh so
it correctly reports failures.

Change-Id: I2062d9c00ebffcc98ba75a12f480e4dd728ee080
2015-04-17 13:23:25 +10:00
Ian Wienand
9b845da478 Fix die_if_not_set tests
The "die_if_not_set" test has the LINENO as a positional argument.
The existing tests are not passing this in, so they are failing.

Along with this, remove the "-x" from the invocation and hide the
output of the tests that are expected to fail to avoid confusion.

Change-Id: Ibf6b9d7bb72b9f92831e1a90292ff8b0bec7faea
2015-04-17 13:23:25 +10:00
Ian Wienand
9b0ebc44f4 Move function.sh to test_functions.sh
run_tests.sh runs tests starting with test_*

The existing test_functions.sh is really testing true/false.  Move
that to test_truefalse.sh

Then move functions.sh to test_functions.sh.  This will ensure it is
run during unit testing from run-tests.sh

Change-Id: I959ac38c946da1fb47458b8c4f09157f74f0e644
2015-04-17 13:23:25 +10:00
Sean Dague
537532931d Make changes such that -o nounset runs
This makes a bunch of variable cleanups that will let -o nounset
function, for the time being we hide nounset behind another setting
variable so that it's not on by default.

Because this is bash, and things are only executed on demand, this
probably only works in the config it was run in. Expect cleaning up
all the paths to be something that takes quite a while.

This also includes a new set of unit tests around the trueorfalse
function, because my change in how it worked, didn't. Tests are good
m'kay.

Change-Id: I71a896623ea9e1f042a73dc0678ce85acf0dc87d
2015-01-15 13:06:14 -05:00