diff options
author | IWASE Yusuke <iwase.yusuke0@gmail.com> | 2017-03-16 14:44:59 +0900 |
---|---|---|
committer | IWASE Yusuke <iwase.yusuke0@gmail.com> | 2017-03-16 16:14:20 +0900 |
commit | afc1fcb1e37d34813dcaede88773956642bdd6c8 (patch) | |
tree | 6816883d0c174a51360d42273882e709de6ab45c /test/scenario_test | |
parent | 0f102be98671abc253e2e73aba15073458c1e444 (diff) |
test/lib: Move noseplugin.py to test/lib module directory
To enable to use "noseplugin" as the Python module from the absolute
import scope in scenario_test, this patch moves noseplugin.py to
test/lib module directory.
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
Diffstat (limited to 'test/scenario_test')
22 files changed, 21 insertions, 50 deletions
diff --git a/test/scenario_test/bgp_router_test.py b/test/scenario_test/bgp_router_test.py index 24f86e77..1a92a1b3 100644 --- a/test/scenario_test/bgp_router_test.py +++ b/test/scenario_test/bgp_router_test.py @@ -23,7 +23,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/bgp_zebra_test.py b/test/scenario_test/bgp_zebra_test.py index 8857f801..48d4dd14 100644 --- a/test/scenario_test/bgp_zebra_test.py +++ b/test/scenario_test/bgp_zebra_test.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/evpn_test.py b/test/scenario_test/evpn_test.py index 5e2637c8..00760d15 100644 --- a/test/scenario_test/evpn_test.py +++ b/test/scenario_test/evpn_test.py @@ -23,7 +23,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/flow_spec_test.py b/test/scenario_test/flow_spec_test.py index 89918f6b..17a36028 100644 --- a/test/scenario_test/flow_spec_test.py +++ b/test/scenario_test/flow_spec_test.py @@ -23,7 +23,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import BGP_FSM_ESTABLISHED diff --git a/test/scenario_test/global_policy_test.py b/test/scenario_test/global_policy_test.py index 13eaabb4..39074f3a 100644 --- a/test/scenario_test/global_policy_test.py +++ b/test/scenario_test/global_policy_test.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/graceful_restart_test.py b/test/scenario_test/graceful_restart_test.py index 926bcbd0..4f3c1563 100644 --- a/test/scenario_test/graceful_restart_test.py +++ b/test/scenario_test/graceful_restart_test.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/ibgp_router_test.py b/test/scenario_test/ibgp_router_test.py index 0a497278..ed476122 100644 --- a/test/scenario_test/ibgp_router_test.py +++ b/test/scenario_test/ibgp_router_test.py @@ -23,7 +23,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/long_lived_graceful_restart_test.py b/test/scenario_test/long_lived_graceful_restart_test.py index 1f07af08..bba633ed 100644 --- a/test/scenario_test/long_lived_graceful_restart_test.py +++ b/test/scenario_test/long_lived_graceful_restart_test.py @@ -23,7 +23,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/noseplugin.py b/test/scenario_test/noseplugin.py deleted file mode 100644 index a53272c3..00000000 --- a/test/scenario_test/noseplugin.py +++ /dev/null @@ -1,29 +0,0 @@ -import os -from nose.plugins import Plugin - -parser_option = None - - -class OptionParser(Plugin): - - def options(self, parser, env=os.environ): - super(OptionParser, self).options(parser, env=env) - parser.add_option('--test-prefix', action="store", dest="test_prefix", default="") - parser.add_option('--gobgp-image', action="store", dest="gobgp_image", default="osrg/gobgp") - parser.add_option('--exabgp-path', action="store", dest="exabgp_path", default="") - parser.add_option('--go-path', action="store", dest="go_path", default="") - parser.add_option('--gobgp-log-level', action="store", - dest="gobgp_log_level", default="info") - parser.add_option('--test-index', action="store", type="int", dest="test_index", default=0) - parser.add_option('--config-format', action="store", dest="config_format", default="yaml") - - def configure(self, options, conf): - super(OptionParser, self).configure(options, conf) - global parser_option - parser_option = options - - if not self.enabled: - return - - def finalize(self, result): - pass diff --git a/test/scenario_test/route_reflector_test.py b/test/scenario_test/route_reflector_test.py index 28845841..a5516dec 100644 --- a/test/scenario_test/route_reflector_test.py +++ b/test/scenario_test/route_reflector_test.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import BGP_FSM_ESTABLISHED diff --git a/test/scenario_test/route_server_as2_test.py b/test/scenario_test/route_server_as2_test.py index 2c79a5fe..bcff8f74 100644 --- a/test/scenario_test/route_server_as2_test.py +++ b/test/scenario_test/route_server_as2_test.py @@ -22,7 +22,7 @@ import time from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/route_server_ipv4_v6_test.py b/test/scenario_test/route_server_ipv4_v6_test.py index 8fdd05b8..9d7e15a7 100644 --- a/test/scenario_test/route_server_ipv4_v6_test.py +++ b/test/scenario_test/route_server_ipv4_v6_test.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import BGP_FSM_ESTABLISHED diff --git a/test/scenario_test/route_server_malformed_test.py b/test/scenario_test/route_server_malformed_test.py index d56b5e2e..08a6467e 100644 --- a/test/scenario_test/route_server_malformed_test.py +++ b/test/scenario_test/route_server_malformed_test.py @@ -23,7 +23,7 @@ import inspect from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import BGP_FSM_ESTABLISHED diff --git a/test/scenario_test/route_server_policy_grpc_test.py b/test/scenario_test/route_server_policy_grpc_test.py index 582b533e..41114d11 100644 --- a/test/scenario_test/route_server_policy_grpc_test.py +++ b/test/scenario_test/route_server_policy_grpc_test.py @@ -27,7 +27,7 @@ from nose.tools import ( assert_false, ) -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/route_server_policy_test.py b/test/scenario_test/route_server_policy_test.py index d1968fcd..bc3637aa 100644 --- a/test/scenario_test/route_server_policy_test.py +++ b/test/scenario_test/route_server_policy_test.py @@ -27,7 +27,7 @@ from nose.tools import ( assert_false, ) -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/route_server_softreset_test.py b/test/scenario_test/route_server_softreset_test.py index 172d3827..ad608837 100644 --- a/test/scenario_test/route_server_softreset_test.py +++ b/test/scenario_test/route_server_softreset_test.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import BGP_FSM_ESTABLISHED diff --git a/test/scenario_test/route_server_test.py b/test/scenario_test/route_server_test.py index e83812a1..a99f1f8b 100644 --- a/test/scenario_test/route_server_test.py +++ b/test/scenario_test/route_server_test.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/route_server_test2.py b/test/scenario_test/route_server_test2.py index ef61a6b9..73f106a8 100644 --- a/test/scenario_test/route_server_test2.py +++ b/test/scenario_test/route_server_test2.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import BGP_FSM_ESTABLISHED diff --git a/test/scenario_test/rtc_test.py b/test/scenario_test/rtc_test.py index 84b8b333..cb9e1e22 100644 --- a/test/scenario_test/rtc_test.py +++ b/test/scenario_test/rtc_test.py @@ -23,7 +23,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import BGP_FSM_ESTABLISHED diff --git a/test/scenario_test/vrf_neighbor_test.py b/test/scenario_test/vrf_neighbor_test.py index 78125169..f0c6de70 100644 --- a/test/scenario_test/vrf_neighbor_test.py +++ b/test/scenario_test/vrf_neighbor_test.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import BGP_FSM_ESTABLISHED diff --git a/test/scenario_test/vrf_neighbor_test2.py b/test/scenario_test/vrf_neighbor_test2.py index cee3bf76..584fc8fa 100644 --- a/test/scenario_test/vrf_neighbor_test2.py +++ b/test/scenario_test/vrf_neighbor_test2.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import ( diff --git a/test/scenario_test/zapi_v3_test.py b/test/scenario_test/zapi_v3_test.py index f11d98e7..3c35903c 100644 --- a/test/scenario_test/zapi_v3_test.py +++ b/test/scenario_test/zapi_v3_test.py @@ -22,7 +22,7 @@ import unittest from fabric.api import local import nose -from noseplugin import OptionParser, parser_option +from lib.noseplugin import OptionParser, parser_option from lib import base from lib.base import BGP_FSM_ESTABLISHED |