clients/tests: test adding IPv4/IPv6 addresses and routes
This commit is contained in:
@@ -149,4 +149,7 @@ clients_tests_expected_files = \
|
|||||||
clients/tests/test-client.check-on-disk/test_004-004.expected \
|
clients/tests/test-client.check-on-disk/test_004-004.expected \
|
||||||
clients/tests/test-client.check-on-disk/test_004-005.expected \
|
clients/tests/test-client.check-on-disk/test_004-005.expected \
|
||||||
clients/tests/test-client.check-on-disk/test_004-006.expected \
|
clients/tests/test-client.check-on-disk/test_004-006.expected \
|
||||||
|
clients/tests/test-client.check-on-disk/test_004-007.expected \
|
||||||
|
clients/tests/test-client.check-on-disk/test_004-008.expected \
|
||||||
|
clients/tests/test-client.check-on-disk/test_004-009.expected \
|
||||||
$(NULL)
|
$(NULL)
|
||||||
|
@@ -0,0 +1,12 @@
|
|||||||
|
location: clients/tests/test-client.py:816:test_004()/7
|
||||||
|
cmd: $NMCLI connection mod con-xx1 ipv4.addresses 192.168.77.5/24 ipv4.routes '2.3.4.5/32 192.168.77.1' ipv6.addresses 1:2:3:4::6/64 ipv6.routes 1:2:3:4:5:6::5/128
|
||||||
|
lang: C
|
||||||
|
returncode: 0
|
||||||
|
stdout: 0 bytes
|
||||||
|
>>>
|
||||||
|
|
||||||
|
<<<
|
||||||
|
stderr: 0 bytes
|
||||||
|
>>>
|
||||||
|
|
||||||
|
<<<
|
@@ -0,0 +1,92 @@
|
|||||||
|
location: clients/tests/test-client.py:818:test_004()/8
|
||||||
|
cmd: $NMCLI con s con-xx1
|
||||||
|
lang: C
|
||||||
|
returncode: 0
|
||||||
|
stdout: 3713 bytes
|
||||||
|
>>>
|
||||||
|
connection.id: con-xx1
|
||||||
|
connection.uuid: UUID-con-xx1-REPLACED-REPLACED-REPLA
|
||||||
|
connection.stable-id: --
|
||||||
|
connection.type: 802-11-wireless
|
||||||
|
connection.interface-name: --
|
||||||
|
connection.autoconnect: yes
|
||||||
|
connection.autoconnect-priority: 0
|
||||||
|
connection.autoconnect-retries: -1 (default)
|
||||||
|
connection.auth-retries: -1
|
||||||
|
connection.timestamp: 0
|
||||||
|
connection.read-only: no
|
||||||
|
connection.permissions: --
|
||||||
|
connection.zone: --
|
||||||
|
connection.master: --
|
||||||
|
connection.slave-type: --
|
||||||
|
connection.autoconnect-slaves: -1 (default)
|
||||||
|
connection.secondaries: --
|
||||||
|
connection.gateway-ping-timeout: 0
|
||||||
|
connection.metered: unknown
|
||||||
|
connection.lldp: default
|
||||||
|
connection.mdns: -1 (default)
|
||||||
|
802-11-wireless.ssid: foobar
|
||||||
|
802-11-wireless.mode: infrastructure
|
||||||
|
802-11-wireless.band: a
|
||||||
|
802-11-wireless.channel: 0
|
||||||
|
802-11-wireless.bssid: --
|
||||||
|
802-11-wireless.rate: 0
|
||||||
|
802-11-wireless.tx-power: 0
|
||||||
|
802-11-wireless.mac-address: --
|
||||||
|
802-11-wireless.cloned-mac-address: --
|
||||||
|
802-11-wireless.generate-mac-address-mask:--
|
||||||
|
802-11-wireless.mac-address-blacklist: --
|
||||||
|
802-11-wireless.mac-address-randomization:default
|
||||||
|
802-11-wireless.mtu: auto
|
||||||
|
802-11-wireless.seen-bssids: --
|
||||||
|
802-11-wireless.hidden: no
|
||||||
|
802-11-wireless.powersave: 0 (default)
|
||||||
|
ipv4.method: auto
|
||||||
|
ipv4.dns: --
|
||||||
|
ipv4.dns-search: --
|
||||||
|
ipv4.dns-options: ""
|
||||||
|
ipv4.dns-priority: 0
|
||||||
|
ipv4.addresses: 192.168.77.5/24
|
||||||
|
ipv4.gateway: --
|
||||||
|
ipv4.routes: { ip = 2.3.4.5/32, nh = 192.168.77.1 }
|
||||||
|
ipv4.route-metric: -1
|
||||||
|
ipv4.route-table: 0 (unspec)
|
||||||
|
ipv4.ignore-auto-routes: no
|
||||||
|
ipv4.ignore-auto-dns: no
|
||||||
|
ipv4.dhcp-client-id: --
|
||||||
|
ipv4.dhcp-timeout: 0 (default)
|
||||||
|
ipv4.dhcp-send-hostname: yes
|
||||||
|
ipv4.dhcp-hostname: --
|
||||||
|
ipv4.dhcp-fqdn: --
|
||||||
|
ipv4.never-default: no
|
||||||
|
ipv4.may-fail: yes
|
||||||
|
ipv4.dad-timeout: -1 (default)
|
||||||
|
ipv6.method: auto
|
||||||
|
ipv6.dns: --
|
||||||
|
ipv6.dns-search: --
|
||||||
|
ipv6.dns-options: ""
|
||||||
|
ipv6.dns-priority: 0
|
||||||
|
ipv6.addresses: 1:2:3:4::6/64
|
||||||
|
ipv6.gateway: --
|
||||||
|
ipv6.routes: { ip = 1:2:3:4:5:6:0:5/128 }
|
||||||
|
ipv6.route-metric: -1
|
||||||
|
ipv6.route-table: 0 (unspec)
|
||||||
|
ipv6.ignore-auto-routes: no
|
||||||
|
ipv6.ignore-auto-dns: no
|
||||||
|
ipv6.never-default: no
|
||||||
|
ipv6.may-fail: yes
|
||||||
|
ipv6.ip6-privacy: -1 (unknown)
|
||||||
|
ipv6.addr-gen-mode: stable-privacy
|
||||||
|
ipv6.dhcp-send-hostname: yes
|
||||||
|
ipv6.dhcp-hostname: --
|
||||||
|
ipv6.token: --
|
||||||
|
proxy.method: none
|
||||||
|
proxy.browser-only: no
|
||||||
|
proxy.pac-url: --
|
||||||
|
proxy.pac-script: --
|
||||||
|
|
||||||
|
<<<
|
||||||
|
stderr: 0 bytes
|
||||||
|
>>>
|
||||||
|
|
||||||
|
<<<
|
@@ -0,0 +1,92 @@
|
|||||||
|
location: clients/tests/test-client.py:818:test_004()/9
|
||||||
|
cmd: $NMCLI con s con-xx1
|
||||||
|
lang: pl_PL.UTF-8
|
||||||
|
returncode: 0
|
||||||
|
stdout: 3731 bytes
|
||||||
|
>>>
|
||||||
|
connection.id: con-xx1
|
||||||
|
connection.uuid: UUID-con-xx1-REPLACED-REPLACED-REPLA
|
||||||
|
connection.stable-id: --
|
||||||
|
connection.type: 802-11-wireless
|
||||||
|
connection.interface-name: --
|
||||||
|
connection.autoconnect: tak
|
||||||
|
connection.autoconnect-priority: 0
|
||||||
|
connection.autoconnect-retries: -1 (default)
|
||||||
|
connection.auth-retries: -1
|
||||||
|
connection.timestamp: 0
|
||||||
|
connection.read-only: nie
|
||||||
|
connection.permissions: --
|
||||||
|
connection.zone: --
|
||||||
|
connection.master: --
|
||||||
|
connection.slave-type: --
|
||||||
|
connection.autoconnect-slaves: -1 (default)
|
||||||
|
connection.secondaries: --
|
||||||
|
connection.gateway-ping-timeout: 0
|
||||||
|
connection.metered: nieznane
|
||||||
|
connection.lldp: default
|
||||||
|
connection.mdns: -1 (default)
|
||||||
|
802-11-wireless.ssid: foobar
|
||||||
|
802-11-wireless.mode: infrastructure
|
||||||
|
802-11-wireless.band: a
|
||||||
|
802-11-wireless.channel: 0
|
||||||
|
802-11-wireless.bssid: --
|
||||||
|
802-11-wireless.rate: 0
|
||||||
|
802-11-wireless.tx-power: 0
|
||||||
|
802-11-wireless.mac-address: --
|
||||||
|
802-11-wireless.cloned-mac-address: --
|
||||||
|
802-11-wireless.generate-mac-address-mask:--
|
||||||
|
802-11-wireless.mac-address-blacklist: --
|
||||||
|
802-11-wireless.mac-address-randomization:default
|
||||||
|
802-11-wireless.mtu: automatyczne
|
||||||
|
802-11-wireless.seen-bssids: --
|
||||||
|
802-11-wireless.hidden: nie
|
||||||
|
802-11-wireless.powersave: 0 (default)
|
||||||
|
ipv4.method: auto
|
||||||
|
ipv4.dns: --
|
||||||
|
ipv4.dns-search: --
|
||||||
|
ipv4.dns-options: ""
|
||||||
|
ipv4.dns-priority: 0
|
||||||
|
ipv4.addresses: 192.168.77.5/24
|
||||||
|
ipv4.gateway: --
|
||||||
|
ipv4.routes: { ip = 2.3.4.5/32, nh = 192.168.77.1 }
|
||||||
|
ipv4.route-metric: -1
|
||||||
|
ipv4.route-table: 0 (unspec)
|
||||||
|
ipv4.ignore-auto-routes: nie
|
||||||
|
ipv4.ignore-auto-dns: nie
|
||||||
|
ipv4.dhcp-client-id: --
|
||||||
|
ipv4.dhcp-timeout: 0 (default)
|
||||||
|
ipv4.dhcp-send-hostname: tak
|
||||||
|
ipv4.dhcp-hostname: --
|
||||||
|
ipv4.dhcp-fqdn: --
|
||||||
|
ipv4.never-default: nie
|
||||||
|
ipv4.may-fail: tak
|
||||||
|
ipv4.dad-timeout: -1 (default)
|
||||||
|
ipv6.method: auto
|
||||||
|
ipv6.dns: --
|
||||||
|
ipv6.dns-search: --
|
||||||
|
ipv6.dns-options: ""
|
||||||
|
ipv6.dns-priority: 0
|
||||||
|
ipv6.addresses: 1:2:3:4::6/64
|
||||||
|
ipv6.gateway: --
|
||||||
|
ipv6.routes: { ip = 1:2:3:4:5:6:0:5/128 }
|
||||||
|
ipv6.route-metric: -1
|
||||||
|
ipv6.route-table: 0 (unspec)
|
||||||
|
ipv6.ignore-auto-routes: nie
|
||||||
|
ipv6.ignore-auto-dns: nie
|
||||||
|
ipv6.never-default: nie
|
||||||
|
ipv6.may-fail: tak
|
||||||
|
ipv6.ip6-privacy: -1 (unknown)
|
||||||
|
ipv6.addr-gen-mode: stable-privacy
|
||||||
|
ipv6.dhcp-send-hostname: tak
|
||||||
|
ipv6.dhcp-hostname: --
|
||||||
|
ipv6.token: --
|
||||||
|
proxy.method: none
|
||||||
|
proxy.browser-only: nie
|
||||||
|
proxy.pac-url: --
|
||||||
|
proxy.pac-script: --
|
||||||
|
|
||||||
|
<<<
|
||||||
|
stderr: 0 bytes
|
||||||
|
>>>
|
||||||
|
|
||||||
|
<<<
|
@@ -813,6 +813,10 @@ class TestNmcli(NmTestBase):
|
|||||||
self.call_nmcli(['connection', 'mod', 'con-xx1', 'ipv6.gateway', '::99'])
|
self.call_nmcli(['connection', 'mod', 'con-xx1', 'ipv6.gateway', '::99'])
|
||||||
self.call_nmcli(['connection', 'mod', 'con-xx1', '802.abc', ''])
|
self.call_nmcli(['connection', 'mod', 'con-xx1', '802.abc', ''])
|
||||||
self.call_nmcli(['connection', 'mod', 'con-xx1', '802-11-wireless.band', 'a'])
|
self.call_nmcli(['connection', 'mod', 'con-xx1', '802-11-wireless.band', 'a'])
|
||||||
|
self.call_nmcli(['connection', 'mod', 'con-xx1', 'ipv4.addresses', '192.168.77.5/24', 'ipv4.routes', '2.3.4.5/32 192.168.77.1', 'ipv6.addresses', '1:2:3:4::6/64', 'ipv6.routes', '1:2:3:4:5:6::5/128'])
|
||||||
|
self.call_nmcli_l(['con', 's', 'con-xx1'],
|
||||||
|
replace_stdout = replace_stdout)
|
||||||
|
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user