We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 3c10984 + 1f8c295 commit 2005fdfCopy full SHA for 2005fdf
src/rest/connector/tests/test_nso.py
@@ -51,6 +51,8 @@ def test_connect_restconf(self, **kwargs):
51
</restconf>
52
"""
53
54
+ # Mock /api to return 404 so connect() falls through to /restconf
55
+ kwargs['mock'].get('http://198.51.100.2:8080/api', status_code=404)
56
kwargs['mock'].get('http://198.51.100.2:8080/restconf', text=response_text)
57
output = connection.connect(verbose=True).text
58
self.assertEqual(output, response_text)
0 commit comments