diff --git a/tests/integration/assets/test_09/cloud-config.yml b/tests/integration/assets/test_09/cloud-config.yml index b11304d9..4303c6cc 100644 --- a/tests/integration/assets/test_09/cloud-config.yml +++ b/tests/integration/assets/test_09/cloud-config.yml @@ -21,5 +21,13 @@ rancher: bond_opts: mode: 1 address: 123.123.123.124/32 + dns: + override: true + search: + - mydomain.com + - example.com + nameservers: + - 208.67.222.123 + - 208.67.220.123 ssh_authorized_keys: - ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC85w9stZyiLQp/DkVO6fqwiShYcj1ClKdtCqgHtf+PLpJkFReSFu8y21y+ev09gsSMRRrjF7yt0pUHV6zncQhVeqsZtgc5WbELY2DOYUGmRn/CCvPbXovoBrQjSorqlBmpuPwsStYLr92Xn+VVsMNSUIegHY22DphGbDKG85vrKB8HxUxGIDxFBds/uE8FhSy+xsoyT/jUZDK6pgq2HnGl6D81ViIlKecpOpWlW3B+fea99ADNyZNVvDzbHE5pcI3VRw8u59WmpWOUgT6qacNVACl8GqpBvQk8sw7O/X9DSZHCKafeD9G5k+GYbAUz92fKWrx/lOXfUXPS3+c8dRIF diff --git a/tests/integration/rostest/test_09_network.py b/tests/integration/rostest/test_09_network.py index 260ec253..6e9a66e9 100644 --- a/tests/integration/rostest/test_09_network.py +++ b/tests/integration/rostest/test_09_network.py @@ -21,7 +21,7 @@ def qemu(request): return q -def test_network_conf(qemu): +def test_network_interfaces_conf(qemu): SSH(qemu).check_call('''cat > test-merge << "SCRIPT" set -x -e @@ -37,6 +37,19 @@ sudo bash test-merge '''.strip()) +def test_network_dns_conf(qemu): + SSH(qemu).check_call('''cat > test-merge << "SCRIPT" +set -x -e + +cat /etc/resolv.conf | grep "search mydomain.com example.com" +cat /etc/resolv.conf | grep "nameserver 208.67.222.123" +cat /etc/resolv.conf | grep "nameserver 208.67.220.123" + +SCRIPT +sudo bash test-merge + '''.strip()) + + def test_network_dns_ros_set(qemu): SSH(qemu).check_call(''' set -x -e diff --git a/tests/integration/rostest/test_10_network_from_url.py b/tests/integration/rostest/test_10_network_from_url.py index d5223242..fa9dd66c 100644 --- a/tests/integration/rostest/test_10_network_from_url.py +++ b/tests/integration/rostest/test_10_network_from_url.py @@ -21,7 +21,7 @@ def qemu(request): return q -def test_network_conf(qemu): +def test_network_interfaces_conf(qemu): SSH(qemu).check_call('''cat > test-merge << "SCRIPT" set -x -e @@ -37,6 +37,19 @@ sudo bash test-merge '''.strip()) +def test_network_dns_conf(qemu): + SSH(qemu).check_call('''cat > test-merge << "SCRIPT" +set -x -e + +cat /etc/resolv.conf | grep "search mydomain.com example.com" +cat /etc/resolv.conf | grep "nameserver 208.67.222.123" +cat /etc/resolv.conf | grep "nameserver 208.67.220.123" + +SCRIPT +sudo bash test-merge + '''.strip()) + + def test_network_dns_ros_set(qemu): SSH(qemu).check_call(''' set -x -e