summaryrefslogtreecommitdiff
path: root/tests/cloud_tests/testcases/modules/apt_configure_proxy.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/cloud_tests/testcases/modules/apt_configure_proxy.py')
-rw-r--r--tests/cloud_tests/testcases/modules/apt_configure_proxy.py22
1 files changed, 22 insertions, 0 deletions
diff --git a/tests/cloud_tests/testcases/modules/apt_configure_proxy.py b/tests/cloud_tests/testcases/modules/apt_configure_proxy.py
new file mode 100644
index 00000000..93ae64c6
--- /dev/null
+++ b/tests/cloud_tests/testcases/modules/apt_configure_proxy.py
@@ -0,0 +1,22 @@
+# This file is part of cloud-init. See LICENSE file for license information.
+
+"""cloud-init Integration Test Verify Script"""
+from tests.cloud_tests.testcases import base
+
+
+class TestAptconfigureProxy(base.CloudTestCase):
+ """Test apt-configure module"""
+
+ def test_proxy_config(self):
+ """Test proxy options added to apt config"""
+ out = self.get_data_file('90cloud-init-aptproxy')
+ self.assertIn(
+ 'Acquire::http::Proxy "http://squid.internal:3128";', out)
+ self.assertIn(
+ 'Acquire::http::Proxy "http://squid.internal:3128";', out)
+ self.assertIn(
+ 'Acquire::ftp::Proxy "ftp://squid.internal:3128";', out)
+ self.assertIn(
+ 'Acquire::https::Proxy "https://squid.internal:3128";', out)
+
+# vi: ts=4 expandtab