

def test_redact_http_basic_auth(self):
    sensitive_outputs = ('https://deadbeaf@example.com', 'https://user:pw@example.com')
    sanitized = 'https://<redacted>@example.com'
    for sensitive_output in sensitive_outputs:
        result = salt.utils.url.redact_http_basic_auth(sensitive_output)
        self.assertEqual(result, sanitized)

dataset/ETHPy150Open saltstack/salt/tests/unit/utils/url_test.py UrlTestCase.test_redact_http_basic_auth/original