Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add initial testing foundation #33

Merged
merged 2 commits into from
Apr 29, 2024
Merged

Add initial testing foundation #33

merged 2 commits into from
Apr 29, 2024

Conversation

NotTheEvilOne
Copy link
Contributor

This PR adds the initial testing foundation:

  • pytest
  • paramiko based mock SSH server

Closes #14

@NotTheEvilOne
Copy link
Contributor Author

Additional note: I do not agree with all formatting rules applied. The still marked "formatting error" for the ternary operator does not make sense at all and mixes condition with return value for one but not both possibilities.

@brueggemann
Copy link
Contributor

brueggemann commented Mar 13, 2024

Additional note: I do not agree with all formatting rules applied. The still marked "formatting error" for the ternary operator does not make sense at all and mixes condition with return value for one but not both possibilities.

I don't really know, which rule was applied on that line, but I think, probably the line was to long with the else statement in the first line, so it did the line break before else?

In my opinion, the else in the second line is better to read, because now it is more visible, that the AUTH_FAILED is part of the ternary the line before

tests/mock_ssh.py Outdated Show resolved Hide resolved
tests/mock_ssh.py Outdated Show resolved Hide resolved
@brueggemann
Copy link
Contributor

Please also use type hints for method arguments and return values

@NotTheEvilOne NotTheEvilOne force-pushed the prs/initial-pytest branch 11 times, most recently from 6164de7 to 3cb57f4 Compare March 19, 2024 18:33
@NotTheEvilOne NotTheEvilOne force-pushed the prs/initial-pytest branch 2 times, most recently from 3d41d87 to b441597 Compare March 26, 2024 10:44
@NotTheEvilOne NotTheEvilOne force-pushed the prs/initial-pytest branch 3 times, most recently from def14ca to 481882d Compare April 8, 2024 19:47
@brueggemann brueggemann merged commit f267d13 into main Apr 29, 2024
2 checks passed
@brueggemann brueggemann deleted the prs/initial-pytest branch April 29, 2024 13:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[framework] unit test template
2 participants