Enabled add gateway to refrain from checking exit code

Fixes bug 1129741

Change-Id: Ibb9a0e1c0f0e5ad610c4f45ae65eb82e25a57b94
This commit is contained in:
Gary Kotton 2013-02-24 10:30:08 +00:00
parent 2f7a01c2e8
commit a757406792
2 changed files with 2 additions and 2 deletions

View File

@ -297,7 +297,7 @@ class IpRouteCommand(IpDeviceCommandBase):
COMMAND = 'route'
def add_gateway(self, gateway, metric=None):
args = ['add', 'default', 'via', gateway]
args = ['replace', 'default', 'via', gateway]
if metric:
args += ['metric', metric]
args += ['dev', self.name]

View File

@ -548,7 +548,7 @@ class TestIpRouteCommand(TestIPCmdBase):
metric = 100
self.route_cmd.add_gateway(gateway, metric)
self._assert_sudo([],
('add', 'default', 'via', gateway,
('replace', 'default', 'via', gateway,
'metric', metric,
'dev', self.parent.name))