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 integration tests #598
Conversation
3838765
to
90336c2
Compare
@qleisan Would you like some feedback already now? If not, please let us know once you do. |
Yes I do! |
Pushed "object oriented" refactoring of test helpers, thx to @mlasch for the suggestion. Odd bug (on my machine) one test executes twice (and fails second time) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My feedback in general, not specific to a certain file/line of code:
- Please use a linter (pylint being the obvious choice)
- Please format the code according to PEP8
- Instead of using the example projects, introduce new executable which can be specifically tailored to the testing needs.
- If any TODOs remain in the code, please explain them well
Thanks for the feedback. I'll fix formatting etc. before I push a non-draft version.
Interesting thought but do we really want this? Any other feedback on the approach to integration testing (anyone) - any conceptual improvements now might save a lot of test development time |
I think it will become increasingly hard have a single target serving two purposes:
I am pretty sure separate binaries are the way to go.
I like the direction (Tests in pytest instead of C, invoking executables, using test cases from the standard). |
Today we have a separation in client and lightclient. I see your point but not sure that introducing a testclient (and testserver, testbootstrapsever) is the best way to go, at least not now. Shall we revisit this once it is more clear what modifications are actually needed in order to support good testability? |
I'd aim for one (configurable) client and one (configurable) server target, not many. One then can build them multiple times, each time with a different set of supported features and run the relevant pytest tests against it.
Feel free to start off with the examples, but when looking at the "Possible improvements" from back then I have the feeling that we will very soon reach a state when dedicated targets, optimized for testing, will be needed. |
I'm glad to see this type of automated testing. Much easier and more reliable to see if something got broken than manual testing. |
Pushed a slim down version that can be merged one default block size is set to 1024 (done in PR#596) |
I'll add CI integration and resolve comments that are still valid (some are outdated) |
I haven't had time to dive into all the details but i really like this approach with integration tests in python, good work! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have no issues beyond what has already been commented by @rettichschnidi
5a4f7dd
to
a24e669
Compare
@rettichschnidi - please review |
Fixed gitlint issue |
The log-files created during the test run should be in the |
@mlasch pushed update with fixes for review comments (thanks!). Tests running |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few things for now, will do a better review (actually looking at the python code) once I can find some more time.
Surely looking much better already!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just can not find the time to review the python code itself. Nevertheless, I am willing to approve after this round.
File generated with 'pylint --generate-rcfile > .pylintrc' pylint --version => pylint 2.6.2 astroid 2.4.2 Python 3.8.5 (default, Jan 27 2021, 15:41:15) [GCC 9.3.0]
Add initial pytest based integration tests
Add initial pytest based integration tests