def test_http_basic_auth_https_only(self):
        kwargs = {
            'url': 'http://example.com',
            'user': 'foo',
            'password': 'bar',
            'https_only': True,
        }
        self.assertRaises(
            ValueError,
            salt.utils.url.add_http_basic_auth,
            **kwargs
        )
Tests that passing a non-https URL with https_only=True will raise a
dataset/ETHPy150Open saltstack/salt/tests/unit/utils/url_test.py/UrlTestCase.test_http_basic_auth_https_only