-
Notifications
You must be signed in to change notification settings - Fork 275
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
tests: Add target support to RepositorySimulator #1587
tests: Add target support to RepositorySimulator #1587
Conversation
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 tried it locally and it looks good to me.
For now, I don't have any concrete suggestions.
99c028c
to
c333ca6
Compare
Pull Request Test Coverage Report for Build 1269142426Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
* Add very simple targets support into simulator * Add documentation for the simulator * Add an example targets test This might need to be tweaked and/or extended as we add tests but the implementation should give a good indication of how to extend it. As an example, non-consistent targets are not yet supported, but making fetch() check for the consistent_snapshot state and respond accordingly should be easy. Signed-off-by: Jussi Kukkonen <[email protected]>
The handling of consistent snapshot was not very clear: try to make it more obvious what is supported and what is not. Signed-off-by: Jussi Kukkonen <[email protected]>
c333ca6
to
59b0b99
Compare
Modified based on feedback, rebased on develop |
This might need to be tweaked and/or extended as we add tests but the
implementation should give a good indication of how to extend it.
As an example, non-consistent targets (or metadata) are not yet supported, but
making fetch() check for the consistent_snapshot state and respond
accordingly should be easy.
Signed-off-by: Jussi Kukkonen [email protected]
This should be useful to properly test consistent targets (#1576 ) and then implement good test coverage for updater in general.
CC @MVrachev, marking you a reviewer as I know you might want to use it. If you have any improvement ideas let me know. A potential one is a way for simulator to verify targets client has downloaded (a helper, so tests could say "assert that my target is correct"), but I figured we'd first write some tests and see where we duplicate code...