Add karaf-based pax-exam so that net-virt can be tested. 90/15390/1
authorSam Hague <shague@redhat.com>
Mon, 16 Feb 2015 23:08:48 +0000 (18:08 -0500)
committerSam Hague <shague@redhat.com>
Mon, 16 Feb 2015 23:08:48 +0000 (18:08 -0500)
commit5a962dd5bc882f27fef847bd0aa8554bbdd699ed
tree341b4bbc1dd8f1024a1abd0800d02b4c1c3810b2
parent25fa9e6ae2b5f06523a91dad51708bda0a3f4dcb
Add karaf-based pax-exam so that net-virt can be tested.

Use the following command to run the NetVirtIT test:

mvn -Dit.test=NetVirtIT verify -Pintegrationtest -Dovsdbserver.ipaddress=192.168.120.31 -Dovsdbserver.port=6640 -Pkarafit

This will start the test and bring up the ovsdb karaf distribution. You should first build the distribution and install it to your local m2 repo. When the odl-ovsdb-openstack feature is fully loaded you can then manual configure the bridge to connect to odl with ovs-vsctl set-manager tcp:192.168.120.1:6640.

By default the integration tests exclude NetVirtIt. This is because the current test cannot get service interfaces to make use of their services. An example is getting the connect interfce from the plugin to initiate and outgoing connection to an ovsdb node. The usual "ServiceHelper.getGlobalInstance" did not work in the karaf pax-exam container so another workaround needs to be found.

The test will wait for 10s for the connection from the ovsdb node. Look for the output: "Try to connect!" before connecting. This message indicates the odl-ovsdb-openstack feature is active and ready to receive connections. The timeout can be increased if needed.

Change-Id: I17a944542b564f456f841623083635ac9c4304d0
Signed-off-by: Sam Hague <shague@redhat.com>
integrationtest/pom.xml
integrationtest/src/test/java/org/opendaylight/ovsdb/integrationtest/netvirt/NetVirtIT.java [new file with mode: 0644]