aboutsummaryrefslogtreecommitdiffstats
path: root/bootstrap/vagrant-onap/lib/functions
diff options
context:
space:
mode:
authorVictor Morales <victor.morales@intel.com>2017-08-16 13:44:28 -0500
committerVictor Morales <victor.morales@intel.com>2017-08-16 13:44:28 -0500
commit965126534574cb0377db6c8f7f7004c072ed403a (patch)
tree350525304295c68916d4196d8fc41bd88dac2c3c /bootstrap/vagrant-onap/lib/functions
parenta39795202418582a6c1ce5ff77191c3acbf36bb3 (diff)
Implement test_install_policy UT
It was missed the Unit test that verifies the installation of policy services. This commit creates that method and also refactors some policy code Change-Id: I58f3f416efc096fc6199fd831bb63293b95157d2 Signed-off-by: Victor Morales <victor.morales@intel.com> Issue-Id: INT-23
Diffstat (limited to 'bootstrap/vagrant-onap/lib/functions')
-rwxr-xr-xbootstrap/vagrant-onap/lib/functions11
1 files changed, 4 insertions, 7 deletions
diff --git a/bootstrap/vagrant-onap/lib/functions b/bootstrap/vagrant-onap/lib/functions
index 9b903d92a..90af2bc40 100755
--- a/bootstrap/vagrant-onap/lib/functions
+++ b/bootstrap/vagrant-onap/lib/functions
@@ -6,15 +6,12 @@ source /var/onap/commons
source /var/onap/_composed_functions
source /var/onap/_onap_functions
+export MTU=$(/sbin/ifconfig | grep MTU | sed 's/.*MTU://' | sed 's/ .*//' |sort -n | head -1)
+export IP_ADDRESS=$(ifconfig eth0 | grep "inet addr" | tr -s ' ' | cut -d' ' -f3 | cut -d':' -f2)
+
mvn_conf_file=/root/.m2/settings.xml
git_src_folder=/opt
-# export_env_vars() - Export environment variables
-function export_env_vars {
- export MTU=$(/sbin/ifconfig | grep MTU | sed 's/.*MTU://' | sed 's/ .*//' |sort -n | head -1)
- export IP_ADDRESS=$(ifconfig eth0 | grep "inet addr" | tr -s ' ' | cut -d' ' -f3 | cut -d':' -f2)
-}
-
# configure_dns() - DNS/GW IP address configuration
function configure_dns {
echo "nameserver 10.0.0.1" >> /etc/resolvconf/resolv.conf.d/head
@@ -51,7 +48,7 @@ function clone_repo {
local repo=$1
local dest_folder=${2:-$git_src_folder/$repo}
if [ ! -d $dest_folder ]; then
- _git_timed clone -b $gerrit_branch --single-branch ${repo_url}${repo} $dest_folder
+ _git_timed clone ${repo_url}${repo} $dest_folder
else
pushd $dest_folder
_git_timed pull