feature/shared file systems: share acceptance tests (#128)
* feature/filestorage: acceptance tests
Implements acceptance tests for `sharedfilesystems/v2/shares`
* sfs/acceptance: create share-network in env script
Adds creation of a share-network in the acceptance test environment
setup script, and stores the network id in an environment variable
* sfs: adds ShareNetworkID to AcceptanceTestChoices
Gets ShareNetworkID from the OS environment variable:
`OS_SHARE_NETWORK_ID`
* sfs: removes hard-coding of the share-network-id
* sfs: add OS_SHARE_NETWORK_ID to acceptance README
* sfs/acceptance: move WaitForStatus to acc. tests
Moves the `WaitForStatus`-function from the actual library to the
acceptance test folder and does not export it
diff --git a/script/acceptancetest_environments/keystonev2-lbaasv1.sh b/script/acceptancetest_environments/keystonev2-lbaasv1.sh
index 103c6fc..c74db62 100644
--- a/script/acceptancetest_environments/keystonev2-lbaasv1.sh
+++ b/script/acceptancetest_environments/keystonev2-lbaasv1.sh
@@ -170,4 +170,25 @@
echo export OS_POOL_NAME="public" >> openrc
echo export OS_FLAVOR_ID=99 >> openrc
echo export OS_FLAVOR_ID_RESIZE=98 >> openrc
+
+# Manila share-network needs to be created
+_IDTOVALUE="-F id -f value"
+_NEUTRON_NET_ID=$(neutron net-list --name private $_IDTOVALUE)
+_NEUTRON_IPV4_SUB=$(neutron subnet-list \
+ --ip_version 4 \
+ --network_id "$_NEUTRON_NET_ID" \
+ $_IDTOVALUE)
+
+manila share-network-create \
+ --neutron-net-id "$_NEUTRON_NET_ID" \
+ --neutron-subnet-id "$_NEUTRON_IPV4_SUB" \
+ --name "acc_share_nw"
+
+_SHARE_NETWORK=$(manila share-network-list \
+ --neutron-net-id "$_NEUTRON_NET_ID" \
+ --neutron-subnet-id "$_NEUTRON_IPV4_SUB" \
+ --name "acc_share_nw" \
+ | awk 'FNR == 4 {print $2}')
+
+echo export OS_SHARE_NETWORK_ID="$_SHARE_NETWORK" >> openrc
source openrc demo