Merge ~chad.smith/cloud-init:sysconfig-has-default into cloud-init:master
| Status: | Merged |
|---|---|
| Merged at revision: | dd03bb411c9a6f10854a3bbc3223b204c3d4d174 |
| Proposed branch: | ~chad.smith/cloud-init:sysconfig-has-default |
| Merge into: | cloud-init:master |
| Diff against target: |
120 lines (+83/-7) 2 files modified
cloudinit/net/sysconfig.py (+7/-7) tests/unittests/test_net.py (+76/-0) |
| Related bugs: |
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Scott Moser | 2017-05-10 | Needs Fixing on 2017-05-10 | |
| Server Team CI bot | continuous-integration | Approve on 2017-05-10 | |
|
Review via email:
|
|||
Commit Message
sysconfig: Raise ValueError when multiple default gateways are present.
Properly set Route.has_
The code was setting a now unused instance attribute Route.has_
LP: # 1687485
Description of the Change
sysconfig: Raise ValueError when multiple default gateways are present.
Fixed setting Route.has_
route already has a default gateway defined. The code was setting
Route.has_
gateway" ValueErrors. Added unit tests to exercise this expected raised
ValueError. Also moved is_ipv6 = subnet.get('ipv6') logic out of a for
loop because we don't need to recalculate the same value every route
iteration.
| Scott Moser (smoser) wrote : | # |
Change commit message to be
Subject less than 75 chars
<blank line>
longer description
Per your message, you fixed something, but then didn't add a unit test to show that that thing was fixed, right?


PASSED: Continuous integration, rev:36ced9641c9 ea4a97c2999cd74 bcf81dc24c67e0 /jenkins. ubuntu. com/server/ job/cloud- init-ci/ 320/ /jenkins. ubuntu. com/server/ job/cloud- init-ci/ nodes=metal- amd64/320 /jenkins. ubuntu. com/server/ job/cloud- init-ci/ nodes=metal- arm64/320 /jenkins. ubuntu. com/server/ job/cloud- init-ci/ nodes=metal- ppc64el/ 320 /jenkins. ubuntu. com/server/ job/cloud- init-ci/ nodes=vm- i386/320
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
Click here to trigger a rebuild: /jenkins. ubuntu. com/server/ job/cloud- init-ci/ 320/rebuild
https:/