X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=transportpce.git;a=blobdiff_plain;f=tests%2Ftransportpce_tests%2F1.2.1%2Ftest_gnpy.py;h=157ee8461bdbe152e094c6ca9f4b72c1d27d2577;hp=3cdb2e4e3e0ed7dab164389035c1bd18174ed9b0;hb=1b290f8e8a33836fcf5960ebbd19ae5afe4b17ce;hpb=b600d0ab8edbd45e0f141c59081567e9d56f50bc diff --git a/tests/transportpce_tests/1.2.1/test_gnpy.py b/tests/transportpce_tests/1.2.1/test_gnpy.py index 3cdb2e4e3..157ee8461 100644 --- a/tests/transportpce_tests/1.2.1/test_gnpy.py +++ b/tests/transportpce_tests/1.2.1/test_gnpy.py @@ -19,6 +19,7 @@ import subprocess import time import unittest import logging +import test_utils class TransportGNPYtesting(unittest.TestCase): @@ -31,18 +32,12 @@ class TransportGNPYtesting(unittest.TestCase): if os.path.isfile("./transportpce_tests/gnpy.log"): os.remove("transportpce_tests/gnpy.log") - @classmethod - def __start_odl(cls): - executable = "../karaf/target/assembly/bin/karaf" - with open('transportpce_tests/odl.log', 'w') as outfile: - cls.odl_process = subprocess.Popen( - ["bash", executable, "server"], stdout=outfile, - stdin=open(os.devnull)) - @classmethod def setUpClass(cls): - cls.__start_odl() + print ("starting opendaylight...") + cls.odl_process = test_utils.start_tpce() time.sleep(30) + print ("opendaylight started") @classmethod def tearDownClass(cls):