[autobackport: sssd-2-12] adding sss_ssh_knownhosts test case#8493
[autobackport: sssd-2-12] adding sss_ssh_knownhosts test case#8493sssd-bot wants to merge 1 commit intoSSSD:sssd-2-12from
Conversation
Reviewed-by: Anuj Borah <aborah@redhat.com> Reviewed-by: Alejandro López <allopez@redhat.com> (cherry picked from commit b4e88e8)
There was a problem hiding this comment.
Code Review
This pull request adds a system test for sss_ssh_knownhosts. The new test contains a syntax error that will prevent it from running. Additionally, it introduces dependencies on external network services, which can cause test flakiness. I've provided a suggestion to fix the syntax and remove the external dependencies to improve test reliability.
| [("sssd.io", True), ("1.1.1.1", True), ("client.test", True), ("asdf.test", False), ("super.bad.hostname", False)], | ||
| ids=["sssd.io", "1.1.1.1", "client.test", "asdf.test", "super.bad.hostname"], |
There was a problem hiding this comment.
There are two issues with the parametrization of this test:
-
Syntax Error: There is a missing comma at the end of line 69, between the list of
argvaluesand theidskeyword argument. This will cause aSyntaxError. -
External Test Dependencies: The test cases for
sssd.ioand1.1.1.1introduce a dependency on external network services. This can lead to flaky tests if the test environment lacks internet access or if external DNS resolution fails. System tests should be self-contained to ensure they are reliable and reproducible.
I've provided a suggestion that fixes the syntax and removes the external dependencies. The client.test case is sufficient for testing a resolvable hostname within the test environment.
| [("sssd.io", True), ("1.1.1.1", True), ("client.test", True), ("asdf.test", False), ("super.bad.hostname", False)], | |
| ids=["sssd.io", "1.1.1.1", "client.test", "asdf.test", "super.bad.hostname"], | |
| [("client.test", True), ("asdf.test", False), ("super.bad.hostname", False)], | |
| ids=["client.test", "asdf.test", "super.bad.hostname"], |
This is an automatic backport of PR#8448 adding sss_ssh_knownhosts test case to branch sssd-2-12, created by @danlavu.
Please make sure this backport is correct.
Note
The commits were cherry-picked without conflicts.
You can push changes to this pull request
Original commits
b4e88e8 - adding sss_ssh_knownhosts test case
Backported commits
Original Pull Request Body