diff options
author | ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp> | 2015-04-04 23:46:01 +0000 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2015-04-14 08:10:28 +0900 |
commit | 75f835725deb42b00d5f746828f2738d15e3bc4f (patch) | |
tree | 5294cc59377f51896fd75a57cdb776f5e2f8bf54 /test/scenario_test/route_server_test.py | |
parent | 18bbb843d2e025af8e1ffd33b7c9a09d1a19c565 (diff) |
api: use gRPC instead of REST
Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
Diffstat (limited to 'test/scenario_test/route_server_test.py')
-rw-r--r-- | test/scenario_test/route_server_test.py | 34 |
1 files changed, 12 insertions, 22 deletions
diff --git a/test/scenario_test/route_server_test.py b/test/scenario_test/route_server_test.py index 7621d628..36ea0b20 100644 --- a/test/scenario_test/route_server_test.py +++ b/test/scenario_test/route_server_test.py @@ -73,18 +73,16 @@ class GoBGPTest(GoBGPTestBase): for quagga_config in self.quagga_configs: if quagga_config.peer_ip == address: for c_dest in quagga_config.destinations.itervalues(): - g_dests = local_rib['Destinations'] exist_n = 0 - for g_dest in g_dests: - if c_dest.prefix == g_dest['Prefix']: + for g_dest in local_rib: + if c_dest.prefix == g_dest['prefix']: exist_n += 1 self.assertEqual(exist_n, 0) else: for c_dest in quagga_config.destinations.itervalues(): - g_dests = local_rib['Destinations'] exist_n = 0 - for g_dest in g_dests: - if c_dest.prefix == g_dest['Prefix']: + for g_dest in local_rib: + if c_dest.prefix == g_dest['prefix']: exist_n += 1 self.assertEqual(exist_n, 1) @@ -152,22 +150,17 @@ class GoBGPTest(GoBGPTestBase): for quagga_config in self.quagga_configs: if quagga_config.peer_ip == address: for c_dest in quagga_config.destinations.itervalues(): - # print "config : ", c_dest.prefix, "my ip !!!" - g_dests = local_rib['Destinations'] exist_n = 0 - for g_dest in g_dests: - # print "gobgp : ", g_dest['Prefix'] - if c_dest.prefix == g_dest['Prefix']: + for g_dest in local_rib: + if c_dest.prefix == g_dest['prefix']: exist_n += 1 self.assertEqual(exist_n, 0) else: for c_dest in quagga_config.destinations.itervalues(): # print "config : ", c_dest.prefix," - g_dests = local_rib['Destinations'] exist_n = 0 - for g_dest in g_dests: - # print "gobgp : ", g_dest['Prefix'] - if c_dest.prefix == g_dest['Prefix']: + for g_dest in local_rib: + if c_dest.prefix == g_dest['prefix']: exist_n += 1 self.assertEqual(exist_n, 1) @@ -241,21 +234,18 @@ class GoBGPTest(GoBGPTestBase): if quagga_config.peer_ip == address: for c_dest in quagga_config.destinations.itervalues(): # print "config : ", c_dest.prefix, "my ip !!!" - g_dests = local_rib['Destinations'] exist_n = 0 - for g_dest in g_dests: - # print "gobgp : ", g_dest['Prefix'] - if c_dest.prefix == g_dest['Prefix']: + for g_dest in local_rib: + if c_dest.prefix == g_dest['prefix']: exist_n += 1 self.assertEqual(exist_n, 0) else: for c_dest in quagga_config.destinations.itervalues(): # print "config : ", c_dest.prefix - g_dests = local_rib['Destinations'] exist_n = 0 - for g_dest in g_dests: + for g_dest in local_rib: # print "gobgp : ", g_dest['Prefix'] - if c_dest.prefix == g_dest['Prefix']: + if c_dest.prefix == g_dest['prefix']: exist_n += 1 self.assertEqual(exist_n, 1) |