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 ssl support #81
Add ssl support #81
Conversation
Current coverage is 96.04% (diff: 100%)@@ master #81 diff @@
==========================================
Files 8 9 +1
Lines 1624 1696 +72
Methods 0 0
Messages 0 0
Branches 0 0
==========================================
+ Hits 1557 1629 +72
Misses 67 67
Partials 0 0
|
e6b8962
to
a7214fa
Compare
@@ -21,6 +24,36 @@ def docker(): | |||
return libdocker.Client(version='auto') | |||
|
|||
|
|||
@pytest.yield_fixture(scope='session') | |||
def ssl_folder(docker_ip_address): |
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.
maybe we can generate and store (commit) ssl cert/key in tests/data for example... and use it in tests
# Don't pull image if it available localy. Helps when developing new docker | ||
# builds | ||
if not docker.images(image): | ||
docker.pull(image) |
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 some pygo/kafka:2.11_0.9.0.1 image locally (pulled on previous make test
in master).
If you (or somebody else) changes this image on docker hub, I'll never pull it (with this code).
For testing new docker builds you can use --docker-image option in pytest.
request.cls.kafka_ssl_port = ksslport | ||
request.cls.ssl_folder = ssl_folder | ||
|
||
def _create_context(self): |
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.
why so implicit?) you pass ssl_folder
to test class. So can implement this helper method in KafkaIntegrationTestCase
class.
Reverted docker.pull to be run on tests whether you have or not image in docker, so we always update it to latest Other review fix
529eb62
to
8658776
Compare
Fixes SSL part of #32 |
No description provided.