Makes v0.6.0 (soon to be v0.6.1) retro-compatible with v0.5.0#82
Conversation
…f present Signed-off-by: Lou Marvin Caraig <loumarvincaraig@gmail.com>
|
From the next release I'd then revert this this so that by importing |
examples/language-analyzer-v0.5.0.py
Outdated
| @@ -0,0 +1,77 @@ | |||
| #!/usr/bin/env python3 | |||
There was a problem hiding this comment.
imo we don't need to include this example. But add a test that checks "normal" grpc code works.
There was a problem hiding this comment.
ok, gonna remove it. BTW how do you propose to test it? I mean the normal gRPC datastub should be guaranteed to work by gRPC itself, isn't it?
There was a problem hiding this comment.
it doesn't work right now on master. So we can break it again in the future occasionally.
I propose something like:
class DummyAnalyzer(pb.AnalyzerServicer):
def NotifyReviewEvent(self, request, context):
return pb.EventResponse(messages=["review"])
def NotifyPushEvent(self, request, context):
return pb.EventResponse(messages=["push"])
class Test:
def test_review():
res = stub.NotifyReviewEvent(event_pb2.ReviewEvent())
self.assertEqual(res.messages, ["review"])There was a problem hiding this comment.
thanks for the tip! done in 8053a25.
I also moved some utility testing so that analyzers could eventually use the mixin for testing purposes.
| if name.startswith("__"): | ||
| continue | ||
|
|
||
| default_func = dct.get(name, func) |
There was a problem hiding this comment.
I knew it's 1 line change!
There was a problem hiding this comment.
yeah I was ignoring if the method is actually defined 😅.
Signed-off-by: Lou Marvin Caraig <loumarvincaraig@gmail.com>
Signed-off-by: Lou Marvin Caraig <loumarvincaraig@gmail.com>
Signed-off-by: Lou Marvin Caraig <loumarvincaraig@gmail.com>
fb9df66 to
8053a25
Compare
No description provided.