diff options
author | ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp> | 2015-11-08 16:29:37 +0900 |
---|---|---|
committer | ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp> | 2015-11-11 00:31:35 +0900 |
commit | 4ee18568a07ce51bf3399a1814ebec82e7d961ad (patch) | |
tree | 6ce5915d54bedb559f23e6acca44f65a431a0fe3 /test/lib | |
parent | 318b3af291c5c1ed36f630fced6a521b136d4d54 (diff) |
test: better name for bridge when TEST_PREFIX is not specified
e.g _br01 => br01
Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
Diffstat (limited to 'test/lib')
-rw-r--r-- | test/lib/base.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/lib/base.py b/test/lib/base.py index 139cecc4..8d27e996 100644 --- a/test/lib/base.py +++ b/test/lib/base.py @@ -100,7 +100,9 @@ def make_gobgp_ctn(tag='gobgp', local_gobgp_path='', from_image='osrg/quagga'): class Bridge(object): def __init__(self, name, subnet='', with_ip=True, self_ip=False): - self.name = '{0}_{1}'.format(TEST_PREFIX, name) + self.name = name + if TEST_PREFIX != '': + self.name = '{0}_{1}'.format(TEST_PREFIX, name) self.with_ip = with_ip if with_ip: self.subnet = netaddr.IPNetwork(subnet) |